Repair enqueque

This commit is contained in:
Ben Adrian Sarmiento
2024-06-17 23:48:21 +02:00
parent ad06d8fea3
commit d53ba8c973
5 changed files with 137 additions and 102 deletions

View File

@@ -49,8 +49,8 @@ type TorrentManager struct {
latestState *LibraryState
inProgressHashes mapset.Set[string]
repairTrigger chan *Torrent
repairQueue mapset.Set[*Torrent]
repairChan chan *Torrent
RepairQueue mapset.Set[*Torrent]
repairRunning bool
repairRunningMu sync.Mutex
@@ -129,7 +129,7 @@ func NewTorrentManager(cfg config.ConfigInterface, api *realdebrid.RealDebrid, w
t.setNewLatestState(t.getCurrentState())
t.TriggerRepair(nil)
t.EnqueueForRepair(nil)
})
return t