From fbd1d7cb1ce4bddb0b13af47cae067b3b5a4d3c9 Mon Sep 17 00:00:00 2001 From: Midorica Date: Mon, 6 Nov 2023 23:35:02 -0500 Subject: [PATCH] fixing CXB render_POST --- titles/cxb/index.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/titles/cxb/index.py b/titles/cxb/index.py index 1597335..8a57f03 100644 --- a/titles/cxb/index.py +++ b/titles/cxb/index.py @@ -111,7 +111,10 @@ class CxbServlet(resource.Resource): subcmd = "" req_url = request.uri.decode() url_split = req_url.split("/") - req_bytes = request.content.getvalue() + try: + req_bytes = request.content.getvalue() + except: + req_bytes = request.content.read().decode("utf-8") try: req_json: Dict = json.loads(req_bytes)