Add job for monitoring bw limit status of tokens
This commit is contained in:
@@ -219,7 +219,7 @@ func (t *TorrentManager) applyMediaInfoDetails(torrent *Torrent) error {
|
||||
return
|
||||
}
|
||||
unrestrict, err := t.UnrestrictFile(file)
|
||||
if utils.IsBWLimitExceeded(err) {
|
||||
if utils.AreAllTokensExpired(err) {
|
||||
bwLimitReached = true
|
||||
return
|
||||
}
|
||||
@@ -337,6 +337,7 @@ func (t *TorrentManager) mountNewDownloads() {
|
||||
downloads := t.rd.GetDownloads()
|
||||
mountedCount := 0
|
||||
for i := range downloads {
|
||||
downloads[i].Token = token
|
||||
isRealDebrid := strings.HasPrefix(downloads[i].Link, "https://real-debrid.com/d/")
|
||||
if !isRealDebrid {
|
||||
filename := filepath.Base(downloads[i].Filename)
|
||||
|
||||
Reference in New Issue
Block a user