Skip to content

Commit

Permalink
Merge pull request #17489 from eileenmcnaughton/mod
Browse files Browse the repository at this point in the history
[REF] Remove always NULL param modified_id
  • Loading branch information
seamuslee001 authored Jun 5, 2020
2 parents 1cf7557 + 002afe1 commit c1a3267
Showing 1 changed file with 3 additions and 9 deletions.
12 changes: 3 additions & 9 deletions CRM/Member/Form/MembershipRenewal.php
Original file line number Diff line number Diff line change
Expand Up @@ -598,7 +598,7 @@ protected function submit() {
$pending = ($this->_params['contribution_status_id'] == CRM_Core_PseudoConstant::getKey('CRM_Contribute_BAO_Contribution', 'contribution_status_id', 'Pending'));
$membership = $this->processMembership(
$this->_contactID, $this->_params['membership_type_id'][1], $isTestMembership,
$renewalDate, NULL, $customFieldsFormatted, $numRenewTerms, $this->_membershipId,
$renewalDate, $customFieldsFormatted, $numRenewTerms, $this->_membershipId,
$pending,
$contributionRecurID, $membershipSource, $this->_params['is_pay_later'], CRM_Utils_Array::value('campaign_id',
$this->_params)
Expand Down Expand Up @@ -744,7 +744,6 @@ protected function sendReceipt($membership) {
* @param int $membershipTypeID
* @param bool $is_test
* @param string $changeToday
* @param int $modifiedID
* @param $customFieldsFormatted
* @param $numRenewTerms
* @param int $membershipID
Expand All @@ -758,7 +757,7 @@ protected function sendReceipt($membership) {
* @throws \CRM_Core_Exception
* @throws \CiviCRM_API3_Exception
*/
public function processMembership($contactID, $membershipTypeID, $is_test, $changeToday, $modifiedID, $customFieldsFormatted, $numRenewTerms, $membershipID, $pending, $contributionRecurID, $membershipSource, $isPayLater, $campaignId) {
public function processMembership($contactID, $membershipTypeID, $is_test, $changeToday, $customFieldsFormatted, $numRenewTerms, $membershipID, $pending, $contributionRecurID, $membershipSource, $isPayLater, $campaignId) {
$updateStatusId = FALSE;
$allStatus = CRM_Member_PseudoConstant::membershipStatus();
$format = '%Y%m%d';
Expand Down Expand Up @@ -897,12 +896,7 @@ public function processMembership($contactID, $membershipTypeID, $is_test, $chan
//make status override false.
$memParams['is_override'] = FALSE;

//CRM-4027, create log w/ individual contact.
if ($modifiedID) {
// @todo this param is likely unused now.
$memParams['is_for_organization'] = TRUE;
}
$params['modified_id'] = $modifiedID ?? $contactID;
$params['modified_id'] = $contactID;

//inherit campaign from contrib page.
if (isset($campaignId)) {
Expand Down

0 comments on commit c1a3267

Please sign in to comment.