Skip to content

Commit

Permalink
Merge pull request #11890 from otetard/bugfix/fix-deceases-membership…
Browse files Browse the repository at this point in the history
…-processing

Fix CRM-19920 regression: “Deceased” status could be translated.
  • Loading branch information
eileenmcnaughton authored Mar 29, 2018
2 parents d902822 + acd6890 commit 81b1b26
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion CRM/Member/BAO/Membership.php
Original file line number Diff line number Diff line change
Expand Up @@ -2125,9 +2125,12 @@ public static function setQuickConfigMembershipParameters($membershipOrg, $membe
*/
protected static function updateDeceasedMembersStatuses() {
$count = 0;

$deceasedStatusId = CRM_Core_PseudoConstant::getKey('CRM_Member_BAO_Membership', 'status_id', 'Deceased');

// 'create' context for buildOptions returns only if enabled.
$allStatus = self::buildOptions('status_id', 'create');
if (($deceasedStatusId = array_search('Deceased', $allStatus)) === FALSE) {
if (array_key_exists($deceasedStatusId, $allStatus) === FALSE) {
// Deceased status is an admin status & is required. We want to fail early if
// it is not present or active.
// We could make the case 'some databases just don't use deceased so we will check
Expand Down

0 comments on commit 81b1b26

Please sign in to comment.