From 9c22b67627687a07ce37d2e4f9597d106955fde1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Scharnitzky=20Don=C3=A1t?= Date: Tue, 21 Apr 2020 19:42:47 +0200 Subject: [PATCH] Fixed ip update endpoint --- endpoints.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/endpoints.py b/endpoints.py index ecc887d..1a990fe 100644 --- a/endpoints.py +++ b/endpoints.py @@ -6,6 +6,7 @@ from flask_classful import FlaskView class IPEndpoint(FlaskView): def post(self): - currentconsumer = request.json['ip'] - redis_client.set('currentConsumer', currentconsumer) + consumer = redis_client.get('currentConsumer') + consumer['Host'] = request.json['ip'] + redis_client.set('currentConsumer', consumer) pass