Skip to content

Commit

Permalink
fixed blocklist check
Browse files Browse the repository at this point in the history
  • Loading branch information
Flaminel committed Jan 9, 2025
1 parent 8cba632 commit 1201c8c
Showing 1 changed file with 5 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,11 @@ DownloadServiceFactory downloadServiceFactory

public override async Task ExecuteAsync()
{
if (string.IsNullOrEmpty(_sonarrConfig.Block.Path) && string.IsNullOrEmpty(_radarrConfig.Block.Path) &&
string.IsNullOrEmpty(_lidarrConfig.Block.Path))
bool blocklistIsConfigured = _sonarrConfig.Enabled && !string.IsNullOrEmpty(_sonarrConfig.Block.Path) ||
_radarrConfig.Enabled && !string.IsNullOrEmpty(_radarrConfig.Block.Path) ||
_lidarrConfig.Enabled && !string.IsNullOrEmpty(_lidarrConfig.Block.Path);

if (!blocklistIsConfigured)
{
_logger.LogWarning("no blocklist is configured");
return;
Expand Down

0 comments on commit 1201c8c

Please sign in to comment.