mirror of
https://gitee.com/dify_ai/dify.git
synced 2024-12-03 11:48:08 +08:00
chore: save uploaded file extension as lower case (#10111)
This commit is contained in:
parent
8b9fed75f3
commit
e36f5cb366
@ -35,7 +35,7 @@ class FileService:
|
||||
filename = file.filename
|
||||
if not filename:
|
||||
raise FileNotExistsError
|
||||
extension = filename.split(".")[-1]
|
||||
extension = filename.split(".")[-1].lower()
|
||||
if len(filename) > 200:
|
||||
filename = filename.split(".")[0][:200] + "." + extension
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user