Minor bug in helper/registration.php

  • CLAW Corp
  • Topic Author
  • Offline
  • New Member
  • New Member
More
2 years 6 months ago #153808 by CLAW Corp
Minor bug in helper/registration.php was created by CLAW Corp
This patch eliminates an undefined object when using the row id ($registrationType == 4) and avoids conflict where row id is in the range of event ids. Could probably move the test further up into the $config->get('use_custom_fields_from_parent_event'). I did this to avoid xdebug messages during other debugging on overrides:

*************** class EventbookingHelperRegistration
*** 786,792 ****
              {
                  $event = EventbookingHelperDatabase::getEvent($eventId);
   
!                 if ($event->parent_id > 0)
                  {
                      $eventId = $event->parent_id;
                  }
--- 786,792 ----
              {
                  $event = EventbookingHelperDatabase::getEvent($eventId);
   
!                 if ($registrationType != 4 && $event->parent_id > 0)
                  {
                      $eventId = $event->parent_id;
                  }

Thank you!

Please Log in or Create an account to join the conversation.

Moderators: Tuan Pham Ngoc