X-Git-Url: https://vcs.fsf.org/?a=blobdiff_plain;f=api%2Fv3%2FPledgePayment.php;h=0d17e109658e7efb0235a2162326a1daf8736695;hb=8906b92a00b4907e620e80624fb6ac6baa368bed;hp=994bbbbc5bb45cf4c0e96af95e21f76db45a520c;hpb=6340311ffde8285b896e31b8dabf34d44d04df83;p=civicrm-core.git diff --git a/api/v3/PledgePayment.php b/api/v3/PledgePayment.php index 994bbbbc5b..0d17e10965 100644 --- a/api/v3/PledgePayment.php +++ b/api/v3/PledgePayment.php @@ -2,9 +2,9 @@ /* +--------------------------------------------------------------------+ - | CiviCRM version 4.3 | + | CiviCRM version 4.5 | +--------------------------------------------------------------------+ - | Copyright CiviCRM LLC (c) 2004-2013 | + | Copyright CiviCRM LLC (c) 2004-2014 | +--------------------------------------------------------------------+ | This file is a part of CiviCRM. | | | @@ -32,7 +32,7 @@ * @package CiviCRM_APIv3 * @subpackage API_Pledge_Payment * - * @copyright CiviCRM LLC (c) 2004-2013 + * @copyright CiviCRM LLC (c) 2004-2014 * @version $Id: PledgePayment.php * */ @@ -56,7 +56,7 @@ function civicrm_api3_pledge_payment_create($params) { $paymentParams = $params; - if (empty($params['id']) && !CRM_Utils_Array::value('option.create_new', $params)) { + if (empty($params['id']) && empty($params['option.create_new'])) { $paymentDetails = CRM_Pledge_BAO_PledgePayment::getOldestPledgePayment($params['pledge_id']); if (empty($paymentDetails)) { return civicrm_api3_create_error("There are no unmatched payment on this pledge. Pass in the pledge_payment id to specify one or 'option.create_new' to create one");