Mount youtube videos properly
This commit is contained in:
@@ -97,12 +97,8 @@ func ServeDownloadsList(torMgr *torrent.TorrentManager) ([]byte, error) {
|
||||
filenames := torMgr.DownloadMap.Keys()
|
||||
sort.Strings(filenames)
|
||||
for _, filename := range filenames {
|
||||
download, ok := torMgr.DownloadMap.Get(filename)
|
||||
if !ok {
|
||||
continue
|
||||
}
|
||||
filePath := filepath.Join(config.DOWNLOADS, url.PathEscape(filename))
|
||||
buf.WriteString(fmt.Sprintf("<li><a href=\"/http/%s\">%s</a></li>", filePath, download.Filename))
|
||||
buf.WriteString(fmt.Sprintf("<li><a href=\"/http/%s\">%s</a></li>", filePath, filename))
|
||||
}
|
||||
return buf.Bytes(), nil
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user