Reunify workers, add commands

This commit is contained in:
Ben Sarmiento
2024-01-30 16:27:12 +01:00
parent 4e389fa79c
commit 7794e641ab
7 changed files with 29 additions and 54 deletions

View File

@@ -95,7 +95,7 @@ func (t *TorrentManager) refreshTorrents() []string {
// StartRefreshJob periodically refreshes the torrents
func (t *TorrentManager) StartRefreshJob() {
_ = t.refreshPool.Submit(func() {
_ = t.workerPool.Submit(func() {
t.log.Info("Starting periodic refresh job")
refreshTicker := time.NewTicker(time.Duration(t.Config.GetRefreshEverySecs()) * time.Second)
defer refreshTicker.Stop()