From f03afd225161d6a9de2d845af6e309b714f6719d Mon Sep 17 00:00:00 2001 From: 7a1dd609-d238-4580-9d5f-ee8412b0f5bc <7a1dd609-d238-4580-9d5f-ee8412b0f5bc@bankofchina.com> Date: Sat, 11 Jan 2025 02:01:19 +0800 Subject: [PATCH] fix: TypeError: mapstock() takes 0 positional arguments but 1 was given --- host.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/host.py b/host.py index 2ddb5a9..a8ebe6c 100644 --- a/host.py +++ b/host.py @@ -117,7 +117,7 @@ def ticket(): return data, returnCode @app.route("/mapstock") -def mapstock(): +def mapstock_process(): userId = request.args.get('userid') if userId is None or userId.isdigit() is False or len(str(userId)) != 8: return jsonify({"apiName": "mapstock", "apiInfo": "Save 99 Kilometers in Maps.", "apiUsage": "/mapstock?userid="}) @@ -166,7 +166,7 @@ def mapstock(): return data, returnCode @app.route("/unlock") -def unlock(): +def unlock_process(): userId = request.args.get('userid') if userId is None or userId.isdigit() is False or len(str(userId)) != 8: return jsonify({"apiName": "unlock", "apiInfo": "Unlock All DX Master Charts.", "apiUsage": "/unlock?userid="})