Fix directory listing
This commit is contained in:
@@ -43,7 +43,6 @@ func (t *TorrentManager) RefreshTorrents() []string {
|
|||||||
}
|
}
|
||||||
freshKeys.Add(info.AccessKey)
|
freshKeys.Add(info.AccessKey)
|
||||||
if torrent, exists := allTorrents.Get(info.AccessKey); !exists {
|
if torrent, exists := allTorrents.Get(info.AccessKey); !exists {
|
||||||
t.allAccessKeys.Add(info.AccessKey)
|
|
||||||
allTorrents.Set(info.AccessKey, info)
|
allTorrents.Set(info.AccessKey, info)
|
||||||
} else if !strset.Difference(info.DownloadedIDs, torrent.DownloadedIDs).IsEmpty() {
|
} else if !strset.Difference(info.DownloadedIDs, torrent.DownloadedIDs).IsEmpty() {
|
||||||
mainTorrent := t.mergeToMain(torrent, info)
|
mainTorrent := t.mergeToMain(torrent, info)
|
||||||
@@ -64,6 +63,7 @@ func (t *TorrentManager) RefreshTorrents() []string {
|
|||||||
torrents.Set(accessKey, tor)
|
torrents.Set(accessKey, tor)
|
||||||
updatedPaths = append(updatedPaths, fmt.Sprintf("%s/%s", directory, accessKey))
|
updatedPaths = append(updatedPaths, fmt.Sprintf("%s/%s", directory, accessKey))
|
||||||
})
|
})
|
||||||
|
t.allAccessKeys.Add(accessKey)
|
||||||
return true
|
return true
|
||||||
})
|
})
|
||||||
// removed torrents
|
// removed torrents
|
||||||
|
|||||||
Reference in New Issue
Block a user