summaryrefslogtreecommitdiff
path: root/http/api
diff options
context:
space:
mode:
authoremkael <emkael@tlen.pl>2025-03-05 17:12:07 +0100
committeremkael <emkael@tlen.pl>2025-03-05 17:12:07 +0100
commitf12ff6b0e4e7c7fbf2ee93bae61a1893c733621e (patch)
treefd7c7eae6c0ca3e75b46ff15a1a26ef66ba17e46 /http/api
parente48a3ac7e52706baaa65297f7ec0bd2a176584ba (diff)
Handle diacritics in filename properlyHEADmaster
Diffstat (limited to 'http/api')
-rw-r--r--http/api/api.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/http/api/api.py b/http/api/api.py
index 51b93d1..31d331f 100644
--- a/http/api/api.py
+++ b/http/api/api.py
@@ -152,7 +152,7 @@ def handle_download(response, request, uri_parts=[]):
content = base64.b64decode(output['content'])
response.content_type = 'application/octet-stream'
response.headers_out.add(
- 'Content-Disposition', 'attachment; filename=%s' % (output['name']))
+ 'Content-Disposition', 'attachment; filename=%s' % (output['name'].encode('utf-8')))
response.write(content)
def handler(req):