• Resolved tmuka

    (@tmuka)


    Hi! It looks like this plugin updated on one of my sites, and version 2.2.1 is now throwing PHP Fatal errors as follows.

    [Thu Sep 04 08:51:47.139763 2025] [proxy_fcgi:error] [pid 2880713:tid 140176047203904] [client 10.150.17.9:0] AH01071: Got error 'PHP message: PHP Fatal error: Uncaught TypeError: Cannot access offset of type string on string in /var/www/vhosts/example.com/httpdocs/wp-content/plugins/wp-accessibility/wp-accessibility-stats.php:229\nStack trace:\n#0 /var/www/vhosts/example.com/httpdocs/wp-includes/class-wp-hook.php(324): wpa_stats_action()\n#1 /var/www/vhosts/example.com/httpdocs/wp-includes/class-wp-hook.php(348): WP_Hook->apply_filters()\n#2 /var/www/vhosts/example.com/httpdocs/wp-includes/plugin.php(517): WP_Hook->do_action()\n#3 /var/www/vhosts/example.com/httpdocs/wp-admin/admin-ajax.php(207): do_action()\n#4 {main}\n thrown in /var/www/vhosts/example.com/httpdocs/wp-content/plugins/wp-accessibility/wp-accessibility-stats.php on line 229', referer: https://example.com/

    Hope this helps!

Viewing 11 replies - 1 through 11 (of 11 total)
  • Plugin Author Joe Dolson

    (@joedolson)

    I’ve seen things like that on occasion; I don’t know exactly what triggers it.

    You can completely avoid it by disabling stats collection in the settings.

    Thread Starter tmuka

    (@tmuka)

    Thanks for the quick reply. I can confirm, disabling stats in the plugin settings did stop the Fatal errors. Thanks!

    Seeing the same on a few hundred sites. Apparently $stats and $_REQUEST['stats'] is a string instead of an array. Better data type handling could help.

    I’ll look into, but can you confirm if the setting uses the wpa_track_stats option or something else?

    Disabling this stats setting on each site of a multisite is not easy to do. Is there a way to apply this setting network-wide?

    Just confirming the setting does use wpa_track_stats. Not sure if it may cause other issues, but on all affected sites I spot checked, the option didn’t exist while the UI was showing it was enabled for Site Administrators.

    Bulk adding the option via WP-CLI and fatals are reducing now:
    wp option add wpa_track_stats off --autoload=on

    Plugin Author Joe Dolson

    (@joedolson)

    I’m guessing that when I rewrote the scripts in vanilla JS I inadvertently changed the data type. Will get this fixed.

    Plugin Author Joe Dolson

    (@joedolson)

    Released an update that fixed this issue.

    cnorcross

    (@cnorcross)

    Version 2.2.1 is still the newest one available to download. Where is 2.2.2? I see the reference to it in the Development tab Changelog. Did you forget to update the version number?

    AMGill

    (@amgill)

    This took down my client’s yoga site this morning and showed a critical error. Her clients couldnt log in for the classes. I have deactivated the plugin for now until I see there is a current update.

    Plugin Author Joe Dolson

    (@joedolson)

    I *partially* failed to update the version number, now updated.

    Hello, I updated the plugin today and unfortunately got another fatal error. I have version 2.2.2, but nothing is displayed. When I activate it, I immediately get the message “The plugin cannot be activated because it generates a fatal error.”

Viewing 11 replies - 1 through 11 (of 11 total)

The topic ‘2.2.1 PHP Fatal error: Uncaught TypeError: Cannot access offset of type string’ is closed to new replies.