From 6c5db61a97c0ee919c0f08816dd844133051ddce Mon Sep 17 00:00:00 2001 From: Skia Date: Mon, 28 Feb 2022 09:57:41 +0100 Subject: [PATCH] eboutic: et_autoanswer: don't require 'Auto' to proceed checking the request --- eboutic/views.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/eboutic/views.py b/eboutic/views.py index 05c91e68..abac99ef 100644 --- a/eboutic/views.py +++ b/eboutic/views.py @@ -252,8 +252,6 @@ class EtransactionAutoAnswer(View): if ( not "Amount" in request.GET.keys() or not "BasketID" in request.GET.keys() - or not "Auto" - in request.GET.keys() # If not in the request it means the payment has been refused or not "Error" in request.GET.keys() or not "Sig" in request.GET.keys() ): @@ -271,7 +269,10 @@ class EtransactionAutoAnswer(View): ) except: return HttpResponse("Bad signature", status=400) - if request.GET["Error"] == "00000": + # Payment authorized: + # * 'Error' is '00000' + # * 'Auto' is in the request + if request.GET["Error"] == "00000" and "Auto" in request.GET.keys(): try: with transaction.atomic(): b = (