Skip to content

Commit

Permalink
Fix missing contactID when registering for paid event from waitlist
Browse files Browse the repository at this point in the history
  • Loading branch information
mattwire committed May 22, 2022
1 parent 3a3bd22 commit 58bbfaf
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions CRM/Event/Form/Registration/Confirm.php
Original file line number Diff line number Diff line change
Expand Up @@ -524,6 +524,12 @@ public function postProcess() {
$value['email'] = CRM_Utils_Array::valueByRegexKey('/^email-/', $value);
}

// If registering from waitlist participant_id is set but contact_id is not.
// We need a contact ID to process the payment so set the "primary" contact ID.
if (empty($value['contact_id'])) {
$value['contact_id'] = $contactID;
}

if (is_object($payment)) {
// Not quite sure why we don't just user $value since it contains the data
// from result
Expand Down

0 comments on commit 58bbfaf

Please sign in to comment.