From a54689fbc4010b326d99d43aed51ad97c11db7f4 Mon Sep 17 00:00:00 2001 From: Mark McDowall Date: Sun, 25 Aug 2013 12:41:40 -0700 Subject: [PATCH] Appending .nzb to name when sent to nzbget --- .../NzbgetProviderTests/DownloadNzbFixture.cs | 4 ++-- NzbDrone.Core/Download/Clients/Nzbget/NzbgetClient.cs | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/NzbDrone.Core.Test/Download/DownloadClientTests/NzbgetProviderTests/DownloadNzbFixture.cs b/NzbDrone.Core.Test/Download/DownloadClientTests/NzbgetProviderTests/DownloadNzbFixture.cs index 937a39aaf..638613108 100644 --- a/NzbDrone.Core.Test/Download/DownloadClientTests/NzbgetProviderTests/DownloadNzbFixture.cs +++ b/NzbDrone.Core.Test/Download/DownloadClientTests/NzbgetProviderTests/DownloadNzbFixture.cs @@ -16,7 +16,7 @@ namespace NzbDrone.Core.Test.Download.DownloadClientTests.NzbgetProviderTests public class DownloadNzbFixture : CoreTest { private const string _url = "http://www.nzbdrone.com"; - private const string _title = "30 Rock - S01E01 - Pilot [HDTV-720p]"; + private const string _title = "30.Rock.S01E01.Pilot.720p.hdtv"; private RemoteEpisode _remoteEpisode; [SetUp] @@ -54,7 +54,7 @@ namespace NzbDrone.Core.Test.Download.DownloadClientTests.NzbgetProviderTests { Mocker.GetMock() .Setup(s => s.PostCommand("192.168.5.55:6789", "nzbget", "pass", - It.Is(c => c.Equals("{\"method\":\"appendurl\",\"params\":[\"30 Rock - S01E01 - Pilot [HDTV-720p]\",\"TV\",50,false,\"http://www.nzbdrone.com\"]}")))) + It.Is(c => c.Equals("{\"method\":\"appendurl\",\"params\":[\"30.Rock.S01E01.Pilot.720p.hdtv.nzb\",\"TV\",50,false,\"http://www.nzbdrone.com\"]}")))) .Returns("{\"version\": \"1.1\",\"result\": true}"); Mocker.Resolve().DownloadNzb(_remoteEpisode); diff --git a/NzbDrone.Core/Download/Clients/Nzbget/NzbgetClient.cs b/NzbDrone.Core/Download/Clients/Nzbget/NzbgetClient.cs index 5c9f1374e..6fd7a9061 100644 --- a/NzbDrone.Core/Download/Clients/Nzbget/NzbgetClient.cs +++ b/NzbDrone.Core/Download/Clients/Nzbget/NzbgetClient.cs @@ -25,7 +25,7 @@ namespace NzbDrone.Core.Download.Clients.Nzbget public void DownloadNzb(RemoteEpisode remoteEpisode) { var url = remoteEpisode.Report.NzbUrl; - var title = remoteEpisode.Report.Title; + var title = remoteEpisode.Report.Title + ".nzb"; string cat = _configService.NzbgetTvCategory; int priority = remoteEpisode.IsRecentEpisode() ? (int)_configService.NzbgetRecentTvPriority : (int)_configService.NzbgetOlderTvPriority;