• Resolved ArtGoddess

    (@artgoddess)


    Hi there,

    It seems that in .../wp/wp-content/debug.log appears constantly these PHP notices:

    [17-Sep-2020 07:44:33 UTC] PHP Notice:  Trying to access array offset on value of type bool in /home/server/domain.com/wp/wp-admin/includes/class-wp-privacy-policy-content.php on line 96
    
    [17-Sep-2020 07:44:33 UTC] PHP Notice:  Trying to access array offset on value of type bool in /home/server/domain.com/wp/wp-admin/includes/class-wp-privacy-policy-content.php on line 97

    WordPress 5.5.1. No plugins activated.

    Any thoughts? Many thanks for your assistance, as always 🙂

Viewing 5 replies - 1 through 5 (of 5 total)
  • Hi @artgoddess

    This is an interesting case. However, more information must be provided about the environment.

    Which theme do you use on your website?

    Have you tried to see if the issue happens with default, twentytwenty theme?

    Which PHP version is your web server running on?

    Thread Starter ArtGoddess

    (@artgoddess)

    Thank you @igorradovanov for answering my question.

    I am using a twentytwenty child theme (just some CSS tweaks).

    I have just switched to the twentytwenty theme and the issue persists.

    My PHP version is 7.4.

    Again, many thanks.

    Hi,

    WordPress Core producing these Errors:

    Quick fix : PHP ?? null coalescing operator

    $old[ $key ] = array(
    ‘plugin_name’ => $data[‘plugin_name’],
    ‘policy_text’ => $data[‘policy_text’],
    );

    Changed line no 96,97 to

    $old[ $key ] = array(
    ‘plugin_name’ => $data[‘plugin_name’] ?? ”,
    ‘policy_text’ => $data[‘policy_text’] ?? ”,
    );

    Also please check this link for ‘unset’ property removal

    https://core.trac.wordpress.org/changeset/48836

    Thanks.

    Thread Starter ArtGoddess

    (@artgoddess)

    Nice @phptechie I hope this change in code is published in next update. I’d prefer not to edit WP files directly 😉

    Thank you very much for your answer!

    Thread Starter ArtGoddess

    (@artgoddess)

    As far as I can see this issue has been solved with WordPress updates. Many thanks!!

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

The topic ‘class-wp-privacy-policy-content.php on line 96 and 97’ is closed to new replies.