Skip to content
Snippets Groups Projects
Unverified Commit f3b471a9 authored by Seamus Lee's avatar Seamus Lee Committed by GitHub
Browse files

Merge pull request #17490 from eileenmcnaughton/pending

[Ref] remove calls to, and deprecate, pending function
parents 856dfbdb 0e89200f
No related branches found
No related tags found
No related merge requests found
......@@ -274,15 +274,18 @@ class CRM_Core_Payment_BaseIPN {
/**
* Handled pending contribution status.
*
* @deprecated
*
* @param array $objects
* @param object $transaction
*
* @return bool
*/
public function pending(&$objects, &$transaction) {
CRM_Core_Error::deprecatedFunctionWarning('This function will be removed at some point');
$transaction->commit();
Civi::log()->debug("Returning since contribution status is Pending");
echo "Success: Returning since contribution status is pending<p>";
Civi::log()->debug('Returning since contribution status is Pending');
echo 'Success: Returning since contribution status is pending<p>';
return TRUE;
}
......
......@@ -263,8 +263,9 @@ class CRM_Core_Payment_PayPalIPN extends CRM_Core_Payment_BaseIPN {
if ($status == 'Denied' || $status == 'Failed' || $status == 'Voided') {
return $this->failed($objects, $transaction);
}
elseif ($status == 'Pending') {
return $this->pending($objects, $transaction);
if ($status === 'Pending') {
Civi::log()->debug('Returning since contribution status is Pending');
return;
}
elseif ($status == 'Refunded' || $status == 'Reversed') {
return $this->cancelled($objects, $transaction);
......
......@@ -351,8 +351,8 @@ class CRM_Core_Payment_PayPalProIPN extends CRM_Core_Payment_BaseIPN {
$this->failed($objects, $transaction);
return;
}
elseif ($status == 'Pending') {
$this->pending($objects, $transaction);
if ($status === 'Pending') {
Civi::log()->debug('Returning since contribution status is Pending');
return;
}
elseif ($status == 'Refunded' || $status == 'Reversed') {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment