Repair adjustments 2

This commit is contained in:
Ben Sarmiento
2024-05-01 14:06:54 +02:00
parent 130cc0d7b3
commit b6b59b22e6
6 changed files with 71 additions and 85 deletions

View File

@@ -29,7 +29,7 @@ func CheckFile(directory, torrentName, fileName string, w http.ResponseWriter, r
file, ok := torrent.SelectedFiles.Get(fileName)
if !ok || file.IsDeleted {
log.Warnf("Cannot find file %s from path %s", fileName, req.URL.Path)
http.Error(w, "Cannot find file", http.StatusNotFound)
http.Error(w, "File not found", http.StatusNotFound)
return
}
contentType := getContentMimeType(fileName)