Check for other broken files when repairing

This commit is contained in:
Ben Sarmiento
2024-05-25 01:51:00 +02:00
parent 0a086d7a14
commit abb80b4257
3 changed files with 12 additions and 4 deletions

View File

@@ -159,7 +159,7 @@ func (t *TorrentManager) refreshTorrents() []string {
return false
})
existingIDs.Difference(freshIDs).Each(func(id string) bool {
t.log.Infof("Deleting stale info file %s", id)
// t.log.Infof("Deleting stale info file %s", id)
t.deleteInfoFile(id)
return false
})
@@ -498,8 +498,6 @@ func (t *TorrentManager) persistBins() {
_, err = file.Write(jsonData)
if err != nil {
t.log.Errorf("Failed to write to bins.json file: %v", err)
} else {
t.log.Debug("Successfully saved bins to file")
}
}