Skip to content

Commit

Permalink
Merge pull request #10217 from fuzionnz/CRM-20466-php7.1_only_vars_by…
Browse files Browse the repository at this point in the history
…_ref

Address fatal errors on PHP7.1 - only vars can be passed by reference.
  • Loading branch information
eileenmcnaughton authored Apr 23, 2017
2 parents 43a6933 + ceef521 commit d501975
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
3 changes: 2 additions & 1 deletion api/v3/File.php
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,8 @@ function civicrm_api3_file_update($params) {
$fileDAO->save();
}
$file = array();
_civicrm_api3_object_to_array(clone($fileDAO), $file);
$cloneDAO = clone($fileDAO);
_civicrm_api3_object_to_array($cloneDAO, $file);
return $file;
}

Expand Down
3 changes: 2 additions & 1 deletion api/v3/MembershipStatus.php
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,8 @@ function civicrm_api3_membership_status_update($params) {
$membershipStatusBAO->save();
}
$membershipStatus = array();
_civicrm_api3_object_to_array(clone($membershipStatusBAO), $membershipStatus);
$cloneBAO = clone($membershipStatusBAO);
_civicrm_api3_object_to_array($cloneBAO, $membershipStatus);
$membershipStatus['is_error'] = 0;
return $membershipStatus;
}
Expand Down

0 comments on commit d501975

Please sign in to comment.