Fixed: Only blocklist pending releases when option is checked

This commit is contained in:
Mark McDowall 2021-11-17 07:46:01 -08:00
parent 44a160fa06
commit d11c691a73
1 changed files with 5 additions and 1 deletions
src/Sonarr.Api.V3/Queue

View File

@ -129,8 +129,12 @@ namespace Sonarr.Api.V3.Queue
var pendingRelease = _pendingReleaseService.FindPendingQueueItem(id); var pendingRelease = _pendingReleaseService.FindPendingQueueItem(id);
if (pendingRelease != null) if (pendingRelease != null)
{
if (blocklist)
{ {
_blocklistService.Block(pendingRelease.RemoteEpisode, "Pending release manually blocklisted"); _blocklistService.Block(pendingRelease.RemoteEpisode, "Pending release manually blocklisted");
}
_pendingReleaseService.RemovePendingQueueItems(pendingRelease.Id); _pendingReleaseService.RemovePendingQueueItems(pendingRelease.Id);
return null; return null;