mirror of
https://git.anonymousland.org/anonymousland/synapse-product.git
synced 2025-01-20 11:51:29 -05:00
Check for None
This commit is contained in:
parent
25b32b63ae
commit
f02532baad
@ -150,7 +150,7 @@ class BaseMediaResource(Resource):
|
|||||||
upload_name = None
|
upload_name = None
|
||||||
else:
|
else:
|
||||||
upload_name_utf8 = params.get("filename*", None)
|
upload_name_utf8 = params.get("filename*", None)
|
||||||
if upload_name_utf8.lower().startswith("utf-8''"):
|
if upload_name and upload_name_utf8.lower().startswith("utf-8''"):
|
||||||
upload_name = upload_name_utf8[7:]
|
upload_name = upload_name_utf8[7:]
|
||||||
if upload_name:
|
if upload_name:
|
||||||
upload_name = urlparse.unquote(upload_name)
|
upload_name = urlparse.unquote(upload_name)
|
||||||
|
Loading…
Reference in New Issue
Block a user