diff --git a/CRM/Core/Payment.php b/CRM/Core/Payment.php index c4e4deb2c583..ab955db1497f 100644 --- a/CRM/Core/Payment.php +++ b/CRM/Core/Payment.php @@ -1375,6 +1375,7 @@ public function doPayment(&$params, $component = 'contribute') { } } if (is_a($result, 'CRM_Core_Error')) { + CRM_Core_Error::deprecatedFunctionWarning('payment processors should throw exceptions rather than return errors'); throw new PaymentProcessorException(CRM_Core_Error::getMessages($result)); } return $result;