Update torrent state to error when all files excluded by filters.
Only affects PM, TB and DL
This commit is contained in:
parent
706be01a40
commit
1034f342ed
1 changed files with 14 additions and 0 deletions
|
|
@ -242,6 +242,20 @@ public class Torrents(
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (downloadLinks.Count == 0)
|
||||||
|
{
|
||||||
|
logger.LogInformation("All files excluded by filters (IncludeRegex: {includeRegex}, ExcludeRegex: {excludeRegex}, DownloadMinSize: {downloadMinSize} {torrentInfo}",
|
||||||
|
torrent.IncludeRegex,
|
||||||
|
torrent.ExcludeRegex,
|
||||||
|
torrent.DownloadMinSize,
|
||||||
|
torrent.ToLog());
|
||||||
|
|
||||||
|
await torrentData.UpdateRetry(torrentId, null, torrent.TorrentRetryAttempts);
|
||||||
|
await torrentData.UpdateComplete(torrentId, "All files excluded", DateTimeOffset.Now, false);
|
||||||
|
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
foreach (var downloadLink in downloadLinks)
|
foreach (var downloadLink in downloadLinks)
|
||||||
{
|
{
|
||||||
// Make sure downloads don't get added multiple times
|
// Make sure downloads don't get added multiple times
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue