From: Eileen McNaughton Date: Tue, 28 Jul 2015 10:47:07 +0000 (+1200) Subject: CRM-16925 deprecate isEnabled fn X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=1e483eb55d0e25a12d6e1a762e13bd8f61518616;p=civicrm-core.git CRM-16925 deprecate isEnabled fn --- diff --git a/CRM/Core/Payment.php b/CRM/Core/Payment.php index 7420fe4f6a..938a1a03fd 100644 --- a/CRM/Core/Payment.php +++ b/CRM/Core/Payment.php @@ -202,6 +202,15 @@ abstract class CRM_Core_Payment { return FALSE; } + /** + * Does this processor support cancelling recurring contributions through code. + * + * @return bool + */ + protected function supportsCancelRecurring() { + return method_exists(CRM_Utils_System::getClassName($this), 'cancelSubscription'); + } + /** * Does this processor support pre-approval. * @@ -861,6 +870,8 @@ abstract class CRM_Core_Payment { /** * Check whether a method is present ( & supported ) by the payment processor object. * + * @deprecated - use $paymentProcessor->supports(array('cancelRecurring'); + * * @param string $method * Method to check for. *