Uploaded image for project: 'Planet4'
  1. Planet4
  2. PLANET-4695

Exception: Cannot use object of type WP_Error as array

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Released
    • Icon: Should have Should have
    • 2.31.1
    • 2
    • Block: Counter
    • Sprint #133

      Sentry Issue: PLANET4-6D

      Sentry\Exception\FatalErrorException: Error: Uncaught Error: Cannot use object of type WP_Error as array in /app/source/public/wp-content/plugins/planet4-plugin-gutenberg-blocks/classes/blocks/class-counter.php:110
      Stack trace:
      #0 /app/source/public/wp-content/plugins/planet4-plugin-gutenberg-blocks/classes/blocks/class-base-block.php(33): P4GBKS\Blocks\Counter->prepare_data(Array)
      #1 /app/source/public/wp-includes/class-wp-block-type.php(109): P4GBKS\Blocks\Base_Block->render(Array, '')
      #2 /app/source/public/wp-includes/blocks.php(487): WP_Block_Type->render(Array, '')
      #3 /app/source/public/wp-includes/blocks.php(537): render_block(Array)
      #4 /app/source/public/wp-includes/class-wp-hook.php(288): do_blocks('<!-- wp:html --...')
      #5 /app/source/public/wp-includes/plugin.php(206): WP_Hook->apply_filters('<!-- wp:html --...', Array)
      #6 /app/source/public/wp-content/plugins/timber-library/lib/Post.php(1159): apply_filters('the_content', '<!-- wp:html --...')
      #7 /app/source/public/wp-content/plugins/timber-library/vendor/twig/twig/lib/Twig/Template.php(675): 
        File "/wp-content/plugins/planet4-plugin-gutenberg-blocks/classes/blocks/class-counter.php", line 110
          $response_body = json_decode( $response_api['body'], true );
      

            sdeshmuk Sagar Deshmukh
            nroussos Nikos Roussos
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: