diff --git a/NzbDrone.Core/Providers/EpisodeProvider.cs b/NzbDrone.Core/Providers/EpisodeProvider.cs index 248b8e739..cf065a301 100644 --- a/NzbDrone.Core/Providers/EpisodeProvider.cs +++ b/NzbDrone.Core/Providers/EpisodeProvider.cs @@ -34,7 +34,7 @@ public virtual void AddEpisode(Episode episode) public virtual Episode GetEpisode(long id) { - return _database.SingleOrDefault(id); + return _database.Single(id); } public virtual Episode GetEpisode(int seriesId, int seasonNumber, int episodeNumber) diff --git a/NzbDrone.Core/Providers/IndexerProvider.cs b/NzbDrone.Core/Providers/IndexerProvider.cs index 292a37027..48ad40431 100644 --- a/NzbDrone.Core/Providers/IndexerProvider.cs +++ b/NzbDrone.Core/Providers/IndexerProvider.cs @@ -54,7 +54,7 @@ public virtual void SaveSettings(IndexerSetting settings) public virtual IndexerSetting GetSettings(Type type) { - return _database.SingleOrDefault("WHERE IndexProviderType = @0", type.ToString()); + return _database.Single("WHERE IndexProviderType = @0", type.ToString()); } public virtual void InitializeIndexers(IList indexers) diff --git a/NzbDrone.Core/Providers/MediaFileProvider.cs b/NzbDrone.Core/Providers/MediaFileProvider.cs index fe15eedb5..8b2c39aad 100644 --- a/NzbDrone.Core/Providers/MediaFileProvider.cs +++ b/NzbDrone.Core/Providers/MediaFileProvider.cs @@ -196,7 +196,7 @@ public virtual void Update(EpisodeFile episodeFile) public virtual EpisodeFile GetEpisodeFile(int episodeFileId) { - return _database.SingleOrDefault(episodeFileId); + return _database.Single(episodeFileId); } public virtual List GetEpisodeFiles() diff --git a/NzbDrone.Core/Providers/QualityProvider.cs b/NzbDrone.Core/Providers/QualityProvider.cs index 53529c5ef..fc9fd5353 100644 --- a/NzbDrone.Core/Providers/QualityProvider.cs +++ b/NzbDrone.Core/Providers/QualityProvider.cs @@ -53,7 +53,7 @@ public virtual List GetAllProfiles() public virtual QualityProfile Get(int profileId) { - return _database.SingleOrDefault(profileId); + return _database.Single(profileId); } public virtual void SetupDefaultProfiles()