From 8a1c93fd30bcdeba445f9ee09d3661f5463d2eef Mon Sep 17 00:00:00 2001 From: Ivascu Madalin Date: Tue, 7 Nov 2023 08:09:15 +0000 Subject: [PATCH] fix gifcards redirect --- Magewire/Payment/Method/Giftcards.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Magewire/Payment/Method/Giftcards.php b/Magewire/Payment/Method/Giftcards.php index 91f4b62..331620c 100644 --- a/Magewire/Payment/Method/Giftcards.php +++ b/Magewire/Payment/Method/Giftcards.php @@ -67,7 +67,8 @@ public function mount(): void public function evaluateCompletion(EvaluationResultFactory $resultFactory): EvaluationResultInterface { - if ($this->canSubmit === false) { + + if ($this->canSubmit === false && !$this->isRedirect()) { return $resultFactory->createErrorMessageEvent() ->withCustomEvent('payment:method:error') ->withMessage('Cannot complete payment with giftcards');