Fixed: Don't repeatedly refresh queue when author deleted

pull/1237/head
ta264 3 years ago
parent 3c4c6b855e
commit 8b19f02ade

@ -56,18 +56,21 @@ namespace NzbDrone.Core.Download.TrackedDownloads
{
var updateCacheItems = _cache.Values.Where(x => x.RemoteBook != null && x.RemoteBook.Books.Any(a => a.Id == bookId)).ToList();
foreach (var item in updateCacheItems)
if (updateCacheItems.Any())
{
var parsedBookInfo = Parser.Parser.ParseBookTitle(item.DownloadItem.Title);
item.RemoteBook = null;
if (parsedBookInfo != null)
foreach (var item in updateCacheItems)
{
item.RemoteBook = _parsingService.Map(parsedBookInfo);
var parsedBookInfo = Parser.Parser.ParseBookTitle(item.DownloadItem.Title);
item.RemoteBook = null;
if (parsedBookInfo != null)
{
item.RemoteBook = _parsingService.Map(parsedBookInfo);
}
}
}
_eventAggregator.PublishEvent(new TrackedDownloadRefreshedEvent(GetTrackedDownloads()));
_eventAggregator.PublishEvent(new TrackedDownloadRefreshedEvent(GetTrackedDownloads()));
}
}
public void StopTracking(string downloadId)

Loading…
Cancel
Save