1
0
mirror of https://github.com/Sonarr/Sonarr.git synced 2024-12-14 11:23:42 +02:00

Only use NZBGet's FinalDir if it's not empty

Fixed: Importing from NZBGet
This commit is contained in:
Mark McDowall 2019-04-28 19:23:56 -07:00
parent 05e17b70b5
commit 4e3a5a8823

View File

@ -118,7 +118,7 @@ private IEnumerable<DownloadClientItem> GetHistory()
{
var droneParameter = item.Parameters.SingleOrDefault(p => p.Name == "drone");
var historyItem = new DownloadClientItem();
var itemDir = item.FinalDir ?? item.DestDir;
var itemDir = item.FinalDir.IsNullOrWhiteSpace() ? item.DestDir : item.FinalDir;
historyItem.DownloadClient = Definition.Name;
historyItem.DownloadId = droneParameter == null ? item.Id.ToString() : droneParameter.Value.ToString();