Skip to content

Commit

Permalink
Merge pull request #13739 from seamuslee001/participant_payment_hook_…
Browse files Browse the repository at this point in the history
…correct

Fix the invocation of post hook for ParticipantPayment ensuring that …
  • Loading branch information
eileenmcnaughton authored Mar 1, 2019
2 parents 2169e99 + 5433479 commit 3efecc6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions CRM/Event/BAO/ParticipantPayment.php
Original file line number Diff line number Diff line change
Expand Up @@ -71,10 +71,10 @@ public static function create(&$params, $ids = []) {
$participantPayment->find(TRUE);
}
if ($id) {
CRM_Utils_Hook::post('edit', 'ParticipantPayment', $id, $participantPayment);
CRM_Utils_Hook::post('edit', 'ParticipantPayment', $participantPayment->id, $participantPayment);
}
else {
CRM_Utils_Hook::post('create', 'ParticipantPayment', NULL, $participantPayment);
CRM_Utils_Hook::post('create', 'ParticipantPayment', $participantPayment->id, $participantPayment);
}

//generally if people are creating participant_payments via the api they won't be setting the line item correctly - we can't help them if they are doing complex transactions
Expand Down

0 comments on commit 3efecc6

Please sign in to comment.