From f860ae3b58b8701e6391a50048d914f3168407a5 Mon Sep 17 00:00:00 2001 From: s3lph Date: Wed, 11 Jul 2018 18:24:23 +0200 Subject: [PATCH] Fixed: Wrong argument name check when adding a new product. --- matemat/webserver/pagelets/admin.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/matemat/webserver/pagelets/admin.py b/matemat/webserver/pagelets/admin.py index 412e194..1caab25 100644 --- a/matemat/webserver/pagelets/admin.py +++ b/matemat/webserver/pagelets/admin.py @@ -103,7 +103,7 @@ def handle_admin_change(args: RequestArguments, db: MatematDatabase): db.create_user(username, password, email, member=is_member, admin=is_admin) elif change == 'newproduct': - if 'name' not in args or 'price_member' not in args or 'price_non_member' not in args: + if 'name' not in args or 'pricemember' not in args or 'pricenonmember' not in args: return name = str(args.name) price_member = int(str(args.pricemember))