• Resolved Daniel Iser

    (@danieliser)


    Uncaught Error: Cannot use object of type stdClass as array in /wp-content/plugins/performance-lab/modules/images/webp-uploads/rest-api.php:21 Stack trace: 
    
    #0 /wp-includes/class-wp-hook.php(307): webp_uploads_update_rest_attachment() 
    #1 /wp-includes/plugin.php(191): WP_Hook->apply_filters() 
    #2 /wp-includes/rest-api/endpoints/class-wp-rest-attachments-controller.php(843): apply_filters() 
    #3 /wp-includes/rest-api/endpoints/class-wp-rest-posts-controller.php(377): WP_REST_Attachments_Controller->prepare_item_for_response() 
    #4 /wp-includes/rest-api/class-wp-rest-server.php(1143): WP_REST_Posts_Controller->get_items() 
    #5 /mnt/data/home/502433.cloudw
Viewing 7 replies - 1 through 7 (of 7 total)
  • Plugin Support James Osborne

    (@jamesosborne)

    Hi Daniel,

    Thanks for getting in touch. So we can determine more on this, can you share the following:

    1. Your Site Health information (Tools > Site Health > info )
    2. At what stage do you encounter this error (ie. Each time you try to upload a new image)?
    3. Do you see any REST related errors or warnings when checking your Site Health status (Tools > Site Health > Status)?

    Once we have the above we can investigate this further and provide some troubleshooting suggestions. This may include checking your server configurations or checking for any third party plugin conflicts.

    Thread Starter Daniel Iser

    (@danieliser)

    @jamesosborne – I tried to duplicate it just now, only non passed health check is inactive plugins, no warnings.

    That said I logged it this weekend in Fatal Error Notify during some testing, not exactly sure how.

    If nothing else maybe throw a sanity check that whatever that line is, is in fact an array. Will keep an eye on it.

    Plugin Support James Osborne

    (@jamesosborne)

    Many thanks for the update. Good to know there are not errors or warnings output in your Site Health status. We may be able to try and replicate on our side if you wish to share your Site Health information (Tools > Site Health > info > Copy site info to clipboard). The output here differs to the status which you’ve already checked. Regardless please do let us know if this occurs once more.

    Note also that I’ve also created a GitHub issue, from where the team will investigate this further. See below for more details. Feel free to chime in there.
    https://github.com/WordPress/performance/issues/567

    Plugin Support James Osborne

    (@jamesosborne)

    Just to let you know that we’ve made changes to the plugin in how it handles the error you reported. You can find out more on this below:
    https://github.com/WordPress/performance/issues/567

    I’ll close this support topic, however, if you have any queries let me know.

    Plugin Support James Osborne

    (@jamesosborne)

    Note also that this update will be shipped with with next Performance Lab release, 1.7.0. This is due for 21 November.

    Thread Starter Daniel Iser

    (@danieliser)

    @jamesosborne – Thanks for the heads up, already installed and don’t think we’ve seen it since.

    Take care.

    Plugin Support James Osborne

    (@jamesosborne)

    Excellent! Thanks for the follow up. Best of luck.

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘PHP Error Cannot use object of type stdClass as array’ is closed to new replies.