mirror of
https://github.com/Ernous/TorrServerJellyfin.git
synced 2025-12-19 21:46:11 +05:00
fix VIDEO_TS playlist
This commit is contained in:
@@ -42,6 +42,7 @@ func init() {
|
|||||||
{"video/mp2t", ".ts,.m2ts,.mts"},
|
{"video/mp2t", ".ts,.m2ts,.mts"},
|
||||||
{"video/ogg", ".ogv"},
|
{"video/ogg", ".ogv"},
|
||||||
{"video/webm", ".webm"},
|
{"video/webm", ".webm"},
|
||||||
|
{"video/x-ms-vob", ".vob"},
|
||||||
{"video/x-msvideo", ".avi"},
|
{"video/x-msvideo", ".avi"},
|
||||||
{"video/x-quicktime", ".qt,.mov"},
|
{"video/x-quicktime", ".qt,.mov"},
|
||||||
{"text/srt", ".srt"},
|
{"text/srt", ".srt"},
|
||||||
|
|||||||
@@ -2,6 +2,7 @@ package utils
|
|||||||
|
|
||||||
import (
|
import (
|
||||||
"path/filepath"
|
"path/filepath"
|
||||||
|
"strings"
|
||||||
|
|
||||||
"server/torr/state"
|
"server/torr/state"
|
||||||
)
|
)
|
||||||
@@ -68,7 +69,7 @@ var extAudio = map[string]interface{}{
|
|||||||
}
|
}
|
||||||
|
|
||||||
func GetMimeType(filename string) string {
|
func GetMimeType(filename string) string {
|
||||||
ext := filepath.Ext(filename)
|
ext := strings.ToLower(filepath.Ext(filename))
|
||||||
if _, ok := extVideo[ext]; ok {
|
if _, ok := extVideo[ext]; ok {
|
||||||
return "video/*"
|
return "video/*"
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user