Fix some bugs

This commit is contained in:
2026-01-01 16:03:29 +01:00
parent bb707ebaa0
commit fc35e32c97
2 changed files with 4 additions and 5 deletions

View File

@@ -19,7 +19,6 @@ class AuthController:
auth_api = AuthApi(client)
auth_request = AuthRequestDto(
username=StrictStr(received_data["username"]),
username=StrictStr(received_data["username"]),
key=StrictStr(received_data["key"]),
)
@@ -28,8 +27,8 @@ class AuthController:
print("Success:", response.success)
print("Message:", response.message)
print("Data:", response.data)
return jsonify(response), 200
return jsonify({"success" : response.success, "message" : response.message , "data" : response.data}), 200
except Exception as e:
print(f"Exception when calling AuthAPI->login: {e}")
return jsonify(response), 500
return jsonify({"success" : response.success, "message" : response.message , "data" : response.data}), 500

View File

@@ -29,9 +29,9 @@ class ClientController:
print("Success:", response.success)
print("Message:", response.message)
print("Data:", response.data)
return jsonify(response), 200
return jsonify({"success" : response.success, "message" : response.message , "data" : response.data}), 200
except ApiException as e:
print(f"Exception when calling ClientApi->create: {e}")
return jsonify(response), 500
return jsonify({"success" : response.success, "message" : response.message , "data" : response.data}), 500