Title: Error with WP_Error
Last modified: August 21, 2016

---

# Error with WP_Error

 *  [Joshua David Nelson](https://wordpress.org/support/users/joshuadnelson/)
 * (@joshuadnelson)
 * [12 years, 3 months ago](https://wordpress.org/support/topic/error-with-wp_error/)
 * I’m seeing the following in my error_log every few days:
 * `PHP Fatal error: Cannot use object of type WP_Error as array in plugins/embed-
   github-gist/embed-github-gist.php on line 86`
 * I took a look through the code and that line is: `$json = json_decode($result['
   body'], true);`. Looks like if the `$result` var is an array, it should do this
   line, and if not it should do something else.
 * Cheers,
    Joshua
 * [https://wordpress.org/plugins/embed-github-gist/](https://wordpress.org/plugins/embed-github-gist/)

The topic ‘Error with WP_Error’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/embed-github-gist.svg)
 * [Embed GitHub Gist](https://wordpress.org/plugins/embed-github-gist/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/embed-github-gist/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/embed-github-gist/)
 * [Active Topics](https://wordpress.org/support/plugin/embed-github-gist/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/embed-github-gist/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/embed-github-gist/reviews/)

 * 0 replies
 * 1 participant
 * Last reply from: [Joshua David Nelson](https://wordpress.org/support/users/joshuadnelson/)
 * Last activity: [12 years, 3 months ago](https://wordpress.org/support/topic/error-with-wp_error/)
 * Status: not resolved