Using new PetaPoco Exists method in MediaFileProvider.

This commit is contained in:
Mark McDowall 2011-06-16 21:12:14 -07:00
commit 63023d447d
2 changed files with 9 additions and 9 deletions

View file

@ -75,7 +75,7 @@ namespace NzbDrone.Core.Providers
}
//Check to see if file already exists in the database
if (_database.Single<int>("SELECT COUNT (*) FROM EpisodeFiles WHERE Path =@0", Parser.NormalizePath(filePath)) == 0)
if (!_database.Exists<EpisodeFile>("Path =@0", Parser.NormalizePath(filePath)))
{
var parseResult = Parser.ParseEpisodeInfo(filePath);