CRM-16567 - Zero Amount Contribution returns an error message
authorjitendrapurohit <jitendra.purohit@webaccessglobal.com>
Tue, 26 May 2015 13:01:55 +0000 (18:31 +0530)
committerjitendrapurohit <jitendra.purohit@webaccessglobal.com>
Tue, 26 May 2015 13:01:55 +0000 (18:31 +0530)
CRM/Core/Payment/Dummy.php

index 9daaeba2cf4bf20e7ec391e782fe1de130cb646d..ae9dd49482583586ce8b721eb99706e9b1fc0708 100644 (file)
@@ -89,7 +89,7 @@ class CRM_Core_Payment_Dummy extends CRM_Core_Payment {
     );
     // This means we can test failing transactions by setting a past year in expiry. A full expiry check would
     // be more complete.
-    if (!empty($params['credit_card_exp_date']) && date('Y') >
+    if (!empty($params['credit_card_exp_date']['Y']) && date('Y') >
       CRM_Core_Payment_Form::getCreditCardExpirationYear($params)) {
       $error = new CRM_Core_Error(ts('transaction failed'));
       return $error;