Browse Source
Merge pull request #2032 from tobiasmuehl/patch-2
Detect rar archives by mime type
pull/2045/head
Chris Lu
4 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with
3 additions and
0 deletions
-
weed/util/compression.go
|
|
@ -147,6 +147,9 @@ func IsZstdContent(data []byte) bool { |
|
|
|
if strings.HasSuffix(mtype, "script") { |
|
|
|
return true, true |
|
|
|
} |
|
|
|
if strings.HasSuffix(mtype, "vnd.rar) { |
|
|
|
return false, true |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
if strings.HasPrefix(mtype, "audio/") { |
|
|
|