Fix mime type detection

This commit is contained in:
Nils O. Selåsdal
2026-05-29 22:29:23 +02:00
parent 69488118e7
commit fd205fb8fe
+1 -1
View File
@@ -307,7 +307,7 @@ func getProtocol(r *http.Request) string {
func detectContentType(filename string) string { func detectContentType(filename string) string {
ext := filepath.Ext(filename) ext := filepath.Ext(filename)
mimeType := mime.TypeByExtension(ext) mimeType := mime.TypeByExtension(ext)
if mimeType == "" { if mimeType != "" {
return mimeType return mimeType
} }
return "application/octet-stream" return "application/octet-stream"