From 7b168601ece4f1e4846a62301a825a1de0309047 Mon Sep 17 00:00:00 2001 From: yohan <783b8c87@scimetis.net> Date: Sat, 8 Jun 2024 11:24:10 +0200 Subject: [PATCH] Fix API response codes. --- thermostat.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/thermostat.py b/thermostat.py index ddfbb7c..877b2d2 100755 --- a/thermostat.py +++ b/thermostat.py @@ -212,7 +212,7 @@ class Set_mode_thermostat(Resource): except Exception as e: logging.error(e) return "K0", 400 - return "OK", 201 + return "OK", 200 @ns_thermostat.route('/status') class Status_thermostat(Resource): @@ -246,7 +246,7 @@ class Set_verbosity_thermostat(Resource): logging.getLogger().setLevel(logging.WARNING) else: return "Bad request", 400 - return "OK", 201 + return "OK", 200 except Exception as e: logging.error(e) return "K0", 400