From 9e206c53f3ff785161b1352c0be26ed2d6fff6be Mon Sep 17 00:00:00 2001 From: Jitendra Purohit Date: Sun, 14 May 2017 12:19:15 +0530 Subject: [PATCH] minor fixes --- CRM/Contribute/BAO/Contribution.php | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/CRM/Contribute/BAO/Contribution.php b/CRM/Contribute/BAO/Contribution.php index a1be703347..37518424d9 100644 --- a/CRM/Contribute/BAO/Contribution.php +++ b/CRM/Contribute/BAO/Contribution.php @@ -1734,8 +1734,7 @@ LEFT JOIN civicrm_contribution contribution ON ( componentPayment.contribution_ if ($contriId == $contributionId) { continue; } - $status = CRM_Core_DAO::getFieldValue('CRM_Contribute_DAO_Contribution', $contriId, 'contribution_status_id'); - if ($status == array_search('Completed', $contributionStatuses)) { + if (CRM_Core_PseudoConstant::getName('CRM_Contribute_BAO_Contribution', 'contribution_status_id', $contriId) === 'Completed') { $update = FALSE; } } @@ -1796,8 +1795,7 @@ LEFT JOIN civicrm_contribution contribution ON ( componentPayment.contribution_ if ($contriId == $contributionId) { continue; } - $status = CRM_Core_DAO::getFieldValue('CRM_Contribute_DAO_Contribution', $contriId, 'contribution_status_id'); - if ($status == array_search('Completed', $contributionStatuses)) { + if (CRM_Core_PseudoConstant::getName('CRM_Contribute_BAO_Contribution', 'contribution_status_id', $contriId) === 'Completed') { $update = FALSE; } } -- 2.25.1