Support

Home Forums Wait List Manager Add-on Event Espresso – Wait Lists (EE4.9+) error when testing the messages

Event Espresso – Wait Lists (EE4.9+) error when testing the messages

Posted: January 6, 2020 at 12:05 pm

Viewing 9 reply threads


bksiyengar

January 6, 2020 at 12:05 pm

When I go to messages > Default Message Templates > Registration Promoted From Wait List Notification > Recipient
When I send a test message, I get a critical WordPress error.
This is what I received from WP:

Error Details
=============
An error of type E_ERROR was caused in line 644 of the file /home2/iyengar4/public_html/wp/wp-content/plugins/eea-wait-lists/domain/services/modules/EED_Wait_Lists.module.php. Error message: Uncaught Error: Call to a member function reg_url_link() on null in /home2/iyengar4/public_html/wp/wp-content/plugins/eea-wait-lists/domain/services/modules/EED_Wait_Lists.module.php:644
Stack trace:
#0 /home2/iyengar4/public_html/wp/wp-content/plugins/eea-wait-lists/domain/services/messages/EE_Recipient_Waitlist_Shortcodes.lib.php(72): EED_Wait_Lists::wait_list_checkout_url(Object(EE_Registration))
#1 /home2/iyengar4/public_html/wp/wp-content/plugins/event-espresso-core-reg/core/libraries/shortcodes/EE_Shortcodes.lib.php(184): EE_Recipient_Waitlist_Shortcodes->_parser(‘[RECIPIENT_WAIT…’)
#2 /home2/iyengar4/public_html/wp/wp-content/plugins/event-espresso-core-reg/core/helpers/EEH_Parse_Shortcodes.helper.php(234): EE_Shortcodes->parser(‘[RECIPIENT_WAIT…’, Object(EE_Messages_Addressee), Array)
#3 /home2/iyengar4/public_html/wp/wp-content/plugins/event-espresso-core-reg/core/helpers/EEH_Parse_Shortcodes.helper.php(74): EEH_Parse_Shortcodes->_parse_message_template()
#4 /home2/iyengar4/public_html/wp/wp-cont

Perhaps this is happening because there are no spots opened? Or perhaps the bug can be fixed. If you could let me know that would be great.

Cheers


Josh

  • Support Staff

January 6, 2020 at 2:10 pm

Hi,

You’ll need at least one event set up to avoid the error you saw. If you haven’t set up an event yet, I can advise to set up a simple “testing” event that you’ll delete later.


bksiyengar

January 6, 2020 at 2:21 pm

Hi Josh, I currently have three events set up, but they are all inactive. Do the events need to be active?


Josh

  • Support Staff

January 6, 2020 at 4:06 pm

They wouldn’t normally need to be active. What should happen is there’s a class for generating all of the needed “dummy” data for generating a test message. It doesn’t appear that all of the needed data is getting set up on your site for some reason. What you could do is check the appearance of the message in the preview, then to test the Registration Promoted From Wait List Notification, sign up for the wait list for a sold out event. Then promote the registration from the wait list status. You would need to do this anyway to test the actual functionality of the “Click Here to Finalize Your Registration Now” link.

Even if the dummy data was completely set up (as it normally would be) you wouldn’t get a fatal error while the test message generated. However, if you open the email and clicked through to the page to finalize the registration, you’d end up on an error page.


bksiyengar

January 6, 2020 at 4:27 pm

HI Josh,
I can’t check the appearance of the message by previewing it. That also gives me the error. This is the WP error that appears on the screen:

There has been a critical error on your website. Please check your site admin email inbox for instructions.

Learn more about debugging in WordPress.

And then the rest of the info I sent previously gets sent to me via email. WordPress started doing this since 5.2.

I just noticed that there’s a visual editor. I can preview the message there, so that’s good. But not sure how to fix that error or what’s causing it. I’ll just do some more testing by setting up a dummy event and registering for it and see how that goes. Thanks


Josh

  • Support Staff

January 6, 2020 at 5:08 pm

It’s hard to tell what’s causing the error because there should be dummy data in place of real data for the preview. May I ask do you get similar errors when previewing other message types?


bksiyengar

January 6, 2020 at 5:56 pm

Nope, all the other templates are fine.
I’ll add the add on to the site on my local machine tomorrow and test it there. I’ll let you know if I discover anything.

Thanks


Tony

  • Support Staff

January 6, 2020 at 6:00 pm

Hi there,

We did some digging into this and think we have found the cause.

The messages system generates dummy registration data for previews but to do so it needs a valid event, datetimes, tickets etc to build from so it pulls in the first event from events you have created (that are not draft or trashed) and builds the data out from there.

The above error appears to be happening because the event the preview function is using has multiple tickets assigned on a datetime, the function is generating a dummy registration for each ticket in a single group to give you a preview of say ‘ticket list’ in messages and when EE attempts to pull the ‘primary registrant’ from that group it fails because the transaction (which links it all together) is also using a dummy ID.

I’ve created a ticket to fix this in the preview and prevent the fatal error but for the time being, if you find the event with the lowest ID in Event Espresso -> Events and remove the additional tickets on that event the preview should work.

As an example, this will work: https://monosnap.com/file/1MGCNN81hgeEpZKsCn5gsJVjZDWmvd

This will not: https://monosnap.com/file/aE6ryeqTgrby6KF4nN5X7OVHE8XDXD

The additional ticket is otherwise valid and this will work for ‘real’ registrations because there will be a real transaction id and therefor a real primary registrant but is tripping the preview data.


bksiyengar

January 7, 2020 at 11:01 am

Thanks so much Tony.
That makes sense.
Cheers


Tony

  • Support Staff

January 8, 2020 at 3:32 am

You’re most welcome.

Any further problems just let us know.

Viewing 9 reply threads

The support post ‘Event Espresso – Wait Lists (EE4.9+) error when testing the messages’ is closed to new replies.

Have a question about this support post? Create a new support post in our support forums and include a link to this existing support post so we can help you.

Event Espresso