Prevent race condition with downloaded id

This commit is contained in:
Ben Sarmiento
2024-02-05 03:27:45 +01:00
parent dcdb83349a
commit c8bbfc8650
4 changed files with 38 additions and 26 deletions

View File

@@ -64,7 +64,7 @@ func NewTorrentManager(cfg config.ConfigInterface, api *realdebrid.RealDebrid, w
t.fixers = t.readFixersFromFile()
t.initializeDirectories()
t.workerPool.Submit(func() {
t.refreshTorrents()
t.refreshTorrents(true)
t.setNewLatestState(t.getCurrentState())
t.StartRefreshJob()
t.StartRepairJob()