From be3b890e2f93608a5a2022c94898aea5f5152d78 Mon Sep 17 00:00:00 2001 From: Raphael Michel Date: Thu, 16 Aug 2018 09:36:16 +0200 Subject: [PATCH] PayPal error handling --- src/pretix/plugins/paypal/payment.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/pretix/plugins/paypal/payment.py b/src/pretix/plugins/paypal/payment.py index 20d37ea7d..c9f12dba8 100644 --- a/src/pretix/plugins/paypal/payment.py +++ b/src/pretix/plugins/paypal/payment.py @@ -305,7 +305,7 @@ class Paypal(BasePaymentProvider): } }) if not pp_refund.success(): - raise PaymentException(_('Refunding the amount via PayPal failed: {}').format(refund.error)) + raise PaymentException(_('Refunding the amount via PayPal failed: {}').format(pp_refund.error)) else: sale = paypalrestsdk.Payment.find(refund.payment.info_data['id']) refund.payment.info = json.dumps(sale.to_dict())