Critical Error When Logging ACF > ‘update_option’
-
I have a series of sites with some custom functions along with ACF set up that updates the Blog Name and Blog Description from an ACF input on a customized Website Settings page I built.
update_option('blogname', get_field('platform_title', 'options'), true); // Write custom Site Title
When the ACF Field “Platform Title” is saved, it saves it to the WP Blog Name (typically found in WP Admin: Settings > General). The function works (the title is saved) but I get a Critical Error triggered by your plugin. Here is the Error Log:
2023/01/19 04:16:53 [error] 2422#2422: *38752 FastCGI sent in stderr: "PHP message: PHP Fatal error: Uncaught Error: Call to undefined function get_user_by() in /var/www/xxxxxx.com/htdocs/wp-content/plugins/aryo-activity-log/classes/class-aal-api.php:89 Stack trace: #0 /var/www/xxxxxx.com/htdocs/wp-content/plugins/aryo-activity-log/classes/class-aal-api.php(161): AAL_API->insert() #1 /var/www/xxxxxx.com/htdocs/wp-content/plugins/aryo-activity-log/hooks/class-aal-hook-options.php(105): aal_insert_log() #2 /var/www/xxxxxx.com/htdocs/wp-content/plugins/aryo-activity-log/hooks/class-aal-hook-options.php(96): AAL_Hook_Options->insert_log() #3 /var/www/xxxxxx.com/htdocs/wp-includes/class-wp-hook.php(308): AAL_Hook_Options->hooks_updated_option() #4 /var/www/xxxxxx.com/htdocs/wp-includes/class-wp-hook.php(332): WP_Hook->apply_filters() #5 /var/www/xxxxxx.com/htdocs/wp-includes/plugin.php(517): WP_Hook->do_action() #6 /var/www/st" while reading response header from upstream, client: 76.167.75.113, server: xxxxxx.com, request: "GET /wp-admin/admin.php?page=platform-settings&message=1 HTTP/2.0", upstream: "fastcgi://unix:/var/run/php/php74-fpm-xxxxxx.com.sock:", host: "xxxxxx.com", referrer: "https://xxxxxx.com/wp-admin/admin.php?page=platform-settings"
I’ve had this function for about 18month, and it started doing this maybe 6 months ago. I’ve only now taken the time to try to fix it.
Is there something on my side to do differently?
- The topic ‘Critical Error When Logging ACF > ‘update_option’’ is closed to new replies.