Skip to content

Commit

Permalink
Merge pull request #17556 from eileenmcnaughton/renewline
Browse files Browse the repository at this point in the history
[Ref] Remove never reachable lines.
  • Loading branch information
seamuslee001 authored Jun 9, 2020
2 parents c0bac35 + 2270d87 commit 94e9af5
Showing 1 changed file with 0 additions and 12 deletions.
12 changes: 0 additions & 12 deletions CRM/Member/Form/MembershipRenewal.php
Original file line number Diff line number Diff line change
Expand Up @@ -748,7 +748,6 @@ protected function sendReceipt($membership) {
* @throws \CiviCRM_API3_Exception
*/
public function processMembership($contactID, $membershipTypeID, $is_test, $changeToday, $customFieldsFormatted, $numRenewTerms, $membershipID, $pending, $contributionRecurID, $isPayLater) {
$updateStatusId = FALSE;
$allStatus = CRM_Member_PseudoConstant::membershipStatus();
$format = '%Y%m%d';
$membershipTypeDetails = CRM_Member_BAO_MembershipType::getMembershipTypeDetails($membershipTypeID);
Expand Down Expand Up @@ -855,23 +854,12 @@ public function processMembership($contactID, $membershipTypeID, $is_test, $chan
}
$memParams['membership_activity_status'] = ($pending || $isPayLater) ? 'Scheduled' : 'Completed';
}
//CRM-4555
if ($pending) {
$updateStatusId = array_search('Pending', $allStatus);
}

// Putting this in an IF is precautionary as it seems likely that it would be ignored if empty, but
// perhaps shouldn't be?
if ($contributionRecurID) {
$memParams['contribution_recur_id'] = $contributionRecurID;
}
//CRM-4555
//if we decided status here and want to skip status
//calculation in create( ); then need to pass 'skipStatusCal'.
if ($updateStatusId) {
$memParams['status_id'] = $updateStatusId;
$memParams['skipStatusCal'] = TRUE;
}

//since we are renewing,
//make status override false.
Expand Down

0 comments on commit 94e9af5

Please sign in to comment.