From aa836f6a886c0da862189b6959d5071e427371f5 Mon Sep 17 00:00:00 2001 From: "kay.one" Date: Fri, 17 Jun 2011 20:36:22 -0700 Subject: [PATCH] Fixed exception when GetSeries(int seriesId) where seriesId didnt' exist --- NzbDrone.Core.Test/SeriesProviderTest.cs | Bin 6522 -> 6945 bytes NzbDrone.Core/Providers/SeriesProvider.cs | 2 +- 2 files changed, 1 insertion(+), 1 deletion(-) diff --git a/NzbDrone.Core.Test/SeriesProviderTest.cs b/NzbDrone.Core.Test/SeriesProviderTest.cs index 784ca2e17dc2d4caefe3d652b6b1d37310185e3e..2387bf0e603433decec5b434fff5978b7166b313 100644 GIT binary patch delta 104 zcmexmw9stBMV`se`1mK=F^TKDrYEeanI)l>J0{K)i9d8K}3A=IzEfZ*4$>B*?Eh30BA2JxBvhE delta 16 YcmZ2z_RDC)MV`sl+-95C@fGs`06!WAjsO4v diff --git a/NzbDrone.Core/Providers/SeriesProvider.cs b/NzbDrone.Core/Providers/SeriesProvider.cs index 7d23cf0f5..f7eec2774 100644 --- a/NzbDrone.Core/Providers/SeriesProvider.cs +++ b/NzbDrone.Core/Providers/SeriesProvider.cs @@ -44,7 +44,7 @@ namespace NzbDrone.Core.Providers public virtual Series GetSeries(int seriesId) { - return _database.Single("WHERE seriesId= @0", seriesId); + return _database.SingleOrDefault("WHERE seriesId= @0", seriesId); } ///