From: eileenmcnaugton Date: Fri, 4 Dec 2015 07:36:52 +0000 (+1300) Subject: CRM-11338 backport exception class X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=53b4bf16c4800c9cf1021b8b996e673227437665;p=civicrm-core.git CRM-11338 backport exception class Change-Id: Id4ca37d589e0d21074cae140935e28d18de2d59e --- diff --git a/CRM/Core/Payment/PayPalImpl.php b/CRM/Core/Payment/PayPalImpl.php index db76d97e72..a493d66b8b 100644 --- a/CRM/Core/Payment/PayPalImpl.php +++ b/CRM/Core/Payment/PayPalImpl.php @@ -25,12 +25,16 @@ +--------------------------------------------------------------------+ */ +use Civi\Payment\Exception\PaymentProcessorException; + /** * * @package CRM * @copyright CiviCRM LLC (c) 2004-2015 - * $Id$ - * + */ + +/** + * Class CRM_Core_Payment_PayPalImpl for paypal pro, paypal standard & paypal express. */ class CRM_Core_Payment_PayPalImpl extends CRM_Core_Payment { const CHARSET = 'iso-8859-1'; @@ -51,7 +55,7 @@ class CRM_Core_Payment_PayPalImpl extends CRM_Core_Payment { * @param string $mode * The mode of operation: live or test. * - * @param $paymentProcessor + * @param CRM_Core_Payment $paymentProcessor * * @return \CRM_Core_Payment_PayPalImpl */ @@ -416,7 +420,7 @@ class CRM_Core_Payment_PayPalImpl extends CRM_Core_Payment { */ public function doQuery($params) { if (empty($params['trxn_id'])) { - throw new \Civi\Payment\Exception\PaymentProcessorException('transaction id not set'); + return array(); } $args = array( 'TRANSACTIONID' => $params['trxn_id'], diff --git a/Civi/Payment/Exception/PaymentProcessorException.php b/Civi/Payment/Exception/PaymentProcessorException.php new file mode 100644 index 0000000000..6a441f591f --- /dev/null +++ b/Civi/Payment/Exception/PaymentProcessorException.php @@ -0,0 +1,9 @@ +