Support

Home Forums Event Espresso Premium PHP Fatal Error encountered

PHP Fatal Error encountered

Posted: April 3, 2024 at 6:16 pm


SCBC

April 3, 2024 at 6:16 pm

Hello, we are running the latest version of the Event Espresso plugin and we were encountering a php Fatal error. This was slowing the website and snowballing many other warnings to be logged.
I have fixed the erorr by setting a default value to the string variable of the function but I whish this will be included in your new release so we do not encounter the issue.

The error message:
[04-Apr-2024 00:05:07 UTC] PHP Fatal error: Uncaught TypeError: EventEspresso\core\services\shortcodes\ShortcodesManager::parseContentForShortcodes(): Argument #1 ($content) must be of type string, null given, called in /var/web/site/public_html/wp-content/plugins/event-espresso-core-reg/core/services/shortcodes/ShortcodesManager.php on line 205 and defined in /var/web/site/public_html/wp-content/plugins/event-espresso-core-reg/core/services/shortcodes/ShortcodesManager.php:226

The fix on wp-content/plugins/event-espresso-core-reg/core/services/shortcodes/ShortcodesManager.php:226
editing this line:
public function parseContentForShortcodes(string $content, WP_Post $post): bool
to this:
public function parseContentForShortcodes(string $content=”, WP_Post $post): bool

Thank you


Rio

  • Support Staff

April 3, 2024 at 8:02 pm

Thanks for letting us know. Will pass this to our developer for review.

have a wonderful day.

You must be logged in to reply to this support post. Sign In or Register for an Account

Event Espresso