PPv2: Do not fail hard on refunds that are based on manually confirmed payments (Fixes: #PRETIXEU-AC1)

This commit is contained in:
Martin Gross
2024-07-04 15:12:53 +02:00
parent 06b226f40f
commit 2aa989c293

View File

@@ -949,6 +949,9 @@ class PaypalMethod(BasePaymentProvider):
}
})
response = self.client.execute(req)
except KeyError:
raise PaymentException(_('Refunding the amount via PayPal failed: The original payment does not contain '
'the required information to issue an automated refund.'))
except IOError as e:
refund.order.log_action('pretix.event.order.refund.failed', {
'local_id': refund.local_id,