[SOLUTION] WordPress Jetpack Issue Stats.php Line 219 (version 2.2.5)

Hi guys, sorry that my site (http://ayumilove.net/) was down. I’m not sure how long it was but fortunately, I’m able to bring it up back by disabling and re-enabling the jetpack plugin which was causing the issue PHP Fatal error: Call to undefined function get_editable_roles() in /wp-content/plugins/jetpack/modules/stats.php on line 219

I found out that it was not only my site that was hit by this issue, but many others (thousands of wordpress users) who had this plugin updated from version 2.2 to version 2.2.5 around May 1st 2nd 2013.

To those wordpress users who are facing this similar JetPack issue, you must log out and login to your wordpress admin panel first before proceeding with disable the plugin and re-enabled it.

The jetpack plugin developer (Andy Skelton – automattic engineer) has commented on this issue 10 hours ago (approximately May 2nd 10pm) here is the quote from him : “I must apologize for the bug. I didn’t realize that get_editable_roles function is only loaded in admin, making it potentially unsafe to call from stats_upgrade_options when the next page load after upgrade is a non-admin page. The fix has been committed to the Jetpack plugin. The next bugfix release will include this.

Meanwhile, you should be able to work around the issue by loading just one wp-admin page after upgrading the plugin. This should trigger stats_upgrade_options.” Source: http://wordpress.org/support/topic/updating-jetpack-breaks-wordpress

Leave a Reply

Your email address will not be published. Required fields are marked *