CRM-16925 deprecate isEnabled fn
authorEileen McNaughton <eileen@fuzion.co.nz>
Tue, 28 Jul 2015 10:47:07 +0000 (22:47 +1200)
committerEileen McNaughton <eileen@fuzion.co.nz>
Tue, 28 Jul 2015 10:47:07 +0000 (22:47 +1200)
CRM/Core/Payment.php

index 7420fe4f6a572e155c050e0d3668bb17b9b0e988..938a1a03fd437b07f7511da5d07d66d0a4bc75ff 100644 (file)
@@ -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.
    *