Skip internal paths
This commit is contained in:
@@ -867,11 +867,16 @@ func (t *TorrentManager) UpdateTorrentResponseCache(torrent *Torrent) []string {
|
||||
updatedPaths := []string{}
|
||||
dav, html := t.buildTorrentResponses(torrent)
|
||||
t.AssignedDirectoryCb(torrent, func(directory string) {
|
||||
if strings.HasPrefix(directory, "int__") {
|
||||
return
|
||||
}
|
||||
|
||||
torrents, _ := t.DirectoryMap.Get(directory)
|
||||
torrents.Set(torrent.AccessKey, torrent)
|
||||
|
||||
// torrent responses
|
||||
pathKey := fmt.Sprintf("%s/%s", directory, torrent.AccessKey)
|
||||
updatedPaths = append(updatedPaths, pathKey)
|
||||
// torrent responses
|
||||
newHtml := strings.ReplaceAll(html, "$dir", directory)
|
||||
t.ResponseCache.Set(pathKey+".html", newHtml, 1)
|
||||
newDav := strings.ReplaceAll(dav, "$dir", directory)
|
||||
|
||||
Reference in New Issue
Block a user