Use lowercase filename for content type guess
This commit is contained in:
parent
b5b0626251
commit
52e28eefce
1 changed files with 1 additions and 0 deletions
|
@ -173,6 +173,7 @@ class UiRequest(object):
|
||||||
|
|
||||||
# Get mime by filename
|
# Get mime by filename
|
||||||
def getContentType(self, file_name):
|
def getContentType(self, file_name):
|
||||||
|
file_name = file_name.lower()
|
||||||
content_type = mimetypes.guess_type(file_name)[0]
|
content_type = mimetypes.guess_type(file_name)[0]
|
||||||
|
|
||||||
if content_type:
|
if content_type:
|
||||||
|
|
Loading…
Reference in a new issue