Fixes: Missing default path for Download Station

(cherry picked from commit 4bf3ab1511b4ea25642476bf9df13f91b6f73d76)

Closes #2062
pull/2065/head
Mark McDowall 3 years ago committed by Bogdan
parent 7f8c1ace14
commit 17ff86aaea

@ -308,14 +308,15 @@ namespace NzbDrone.Core.Download.Clients.DownloadStation
{ {
return Settings.TvDirectory.TrimStart('/'); return Settings.TvDirectory.TrimStart('/');
} }
else if (Settings.Category.IsNotNullOrWhiteSpace())
{
var destDir = GetDefaultDir();
var destDir = GetDefaultDir();
if (destDir.IsNotNullOrWhiteSpace() && Settings.Category.IsNotNullOrWhiteSpace())
{
return $"{destDir.TrimEnd('/')}/{Settings.Category}"; return $"{destDir.TrimEnd('/')}/{Settings.Category}";
} }
return null; return destDir.TrimEnd('/');
} }
protected override string AddFromTorrentLink(TorrentInfo release, string hash, string torrentLink) protected override string AddFromTorrentLink(TorrentInfo release, string hash, string torrentLink)

@ -274,14 +274,15 @@ namespace NzbDrone.Core.Download.Clients.DownloadStation
{ {
return Settings.TvDirectory.TrimStart('/'); return Settings.TvDirectory.TrimStart('/');
} }
else if (Settings.Category.IsNotNullOrWhiteSpace())
{
var destDir = GetDefaultDir();
var destDir = GetDefaultDir();
if (destDir.IsNotNullOrWhiteSpace() && Settings.Category.IsNotNullOrWhiteSpace())
{
return $"{destDir.TrimEnd('/')}/{Settings.Category}"; return $"{destDir.TrimEnd('/')}/{Settings.Category}";
} }
return null; return destDir.TrimEnd('/');
} }
protected override string AddFromLink(ReleaseInfo release) protected override string AddFromLink(ReleaseInfo release)

Loading…
Cancel
Save