mirror of
https://mau.dev/maunium/synapse.git
synced 2024-10-01 01:36:05 -04:00
Consistency
This commit is contained in:
parent
66ec6cf9b8
commit
ddf4d2bd98
@ -155,9 +155,9 @@ class BaseMediaResource(Resource):
|
||||
|
||||
# If there isn't check for an ascii name.
|
||||
if not upload_name:
|
||||
upload_name = params.get("filename", None)
|
||||
if upload_name and not is_ascii(upload_name):
|
||||
upload_name = None
|
||||
upload_name_ascii = params.get("filename", None)
|
||||
if upload_name_ascii and is_ascii(upload_name_ascii):
|
||||
upload_name = upload_name_ascii
|
||||
|
||||
if upload_name:
|
||||
upload_name = urlparse.unquote(upload_name)
|
||||
|
Loading…
Reference in New Issue
Block a user