DatabaseTrackInfo: reuse another SQL query
authorAndres G. Aragoneses <knocte@gmail.com>
Thu, 22 Dec 2011 01:01:18 +0000 (01:01 +0000)
committerAndres G. Aragoneses <knocte@gmail.com>
Thu, 22 Dec 2011 01:01:18 +0000 (01:01 +0000)
commit2625a34f50cdae2f6d61c2ab39d4985e5b1d5962
tree2fdd4e625ef03ff9f506f5812f846cf92b62779e
parentfa6503d257f9a041f0dd2ac5ff56024edf4c4478
DatabaseTrackInfo: reuse another SQL query

Reuse another SQL instruction for querying
the TrackID filtering by Uri. The UriField is
now also used, which prevents hardcoding the
Uri column name.

This also prevents that someone could misuse
the GetTrackIdForUri method by passing null
or an empty array, as the primary_sources param
was not validated before.

Signed-off-by: Alexander Kojevnikov <alexk@gnome.org>
src/Core/Banshee.Services/Banshee.Collection.Database/DatabaseTrackInfo.cs