From 1e483eb55d0e25a12d6e1a762e13bd8f61518616 Mon Sep 17 00:00:00 2001 From: Eileen McNaughton Date: Tue, 28 Jul 2015 22:47:07 +1200 Subject: [PATCH] CRM-16925 deprecate isEnabled fn --- CRM/Core/Payment.php | 11 +++++++++++ 1 file changed, 11 insertions(+) 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. * -- 2.25.1