From caf69669cb26660d196fdda9c45ae12472f1f710 Mon Sep 17 00:00:00 2001 From: Ozzie Isaacs Date: Mon, 31 Jul 2023 19:01:15 +0200 Subject: [PATCH] Removed encode utf-8 in dodownload --- cps/helper.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cps/helper.py b/cps/helper.py index be0323a2..92bcb2ad 100644 --- a/cps/helper.py +++ b/cps/helper.py @@ -1042,7 +1042,7 @@ def get_download_link(book_id, book_format, client): headers = Headers() headers["Content-Type"] = mimetypes.types_map.get('.' + book_format, "application/octet-stream") headers["Content-Disposition"] = "attachment; filename=%s.%s; filename*=UTF-8''%s.%s" % ( - quote(file_name.encode('utf-8')), book_format, quote(file_name.encode('utf-8')), book_format) + quote(file_name), book_format, quote(file_name), book_format) return do_download_file(book, book_format, client, data1, headers) else: abort(404)