diff --git a/face_recognition/app/app.py b/face_recognition/app/app.py index 43bf26a..8cd0e5a 100644 --- a/face_recognition/app/app.py +++ b/face_recognition/app/app.py @@ -37,8 +37,7 @@ def new_user_id(): #call like https://face.sguba.de/init_face?id=123&encoded_string=abc def new_face(): id = request.args.get('id', None) - data = dict(request.form) - img=data['content'] + img = request.args.get('encoded_string', None) imgdata = base64.b64decode(img) with open('/tmp/'+str(id), 'wb') as file: file.write(imgdata) @@ -53,8 +52,7 @@ def new_face(): #call like https://face.sguba.de/check_face?id=123&encoded_string=abc def check_face(): id = request.args.get('id', None) - data = dict(request.form) - img=data['content'] + img = request.args.get('encoded_string', None) imgdata = base64.b64decode(img) with open('/tmp/'+str(id), 'wb') as file: file.write(imgdata)