serve video files using the HTML5 video tag (#3967)

This commit is contained in:
Nico Mandery
2016-12-21 09:40:23 +01:00
committed by 无闻
parent 04fbfad2d4
commit adcb1d7c65
4 changed files with 11 additions and 0 deletions

View File

@@ -533,3 +533,7 @@ func IsImageFile(data []byte) bool {
func IsPDFFile(data []byte) bool {
return strings.Index(http.DetectContentType(data), "application/pdf") != -1
}
func IsVideoFile(data []byte) bool {
return strings.Index(http.DetectContentType(data), "video/") != -1
}