Skip to content

Commit

Permalink
no message
Browse files Browse the repository at this point in the history
  • Loading branch information
rogerfar committed Feb 6, 2022
1 parent 6a2533a commit d7b22ab
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,7 @@ export class AddNewTorrentComponent implements OnInit {
torrent.torrentRetryAttempts = this.torrentRetryAttempts;
torrent.downloadRetryAttempts = this.downloadRetryAttempts;
torrent.deleteOnError = this.torrentDeleteOnError;
torrent.lifetime = this.torrentLifetime;

if (this.magnetLink) {
this.torrentService.uploadMagnet(this.magnetLink, torrent).subscribe(
Expand Down
6 changes: 4 additions & 2 deletions server/RdtClient.Service/Services/TorrentRunner.cs
Original file line number Diff line number Diff line change
Expand Up @@ -294,10 +294,12 @@ public async Task Tick()

Log($"Torrent has reached its {torrent.Lifetime} minutes lifetime, marking as error", torrent);

await _torrents.UpdateRetry(torrent.TorrentId, null, 99);
await _torrents.UpdateError(torrent.TorrentId, "Torrent expired in RealDebrid Client");
await _torrents.UpdateRetry(torrent.TorrentId, null, torrent.TorrentRetryAttempts);
await _torrents.UpdateComplete(torrent.TorrentId, $"Torrent lifetime of {torrent.Lifetime} minutes reached", DateTimeOffset.UtcNow, false);
}

torrents = await _torrents.Get();

torrents = torrents.Where(m => m.Completed == null).ToList();

// Only poll Real-Debrid every second when a hub is connected, otherwise every 30 seconds
Expand Down

0 comments on commit d7b22ab

Please sign in to comment.