﻿id	summary	reporter	owner	description	type	status	priority	milestone	component	version	severity	resolution	keywords	cc
12997	Call to a member function get_names() on a non-object in user.php	ipstenu		"This is showing up in my error.log on both 3.0 installes:

{{{ PHP Fatal error:  Call to a member function get_names() on a non-object in /home/ipstenu/public_html/wp-includes/user.php on line 422 }}}

'''solarissmoke''' (on the wp.org forums) did more research and came up with this:

Hi folks,

I'm getting this error when wordpress does cron jobs (by visiting wp-cron.php?doing_wp_cron):

PHP Fatal error: Call to a member function get_names() on a non-object in /wp-includes/user.php on line 422

I think that the function where the error occurs (count_users()) is being called by the wp_version_check function which is one of the regular cron actions. The error suggests that the global variable $wp_roles has not been created by the time the function is called - but I can't track where this should be happening in the first place.

I've looked at my cron options and the only ones there are the defaults (wp_update_plugins, wp_version_check, wp_update_themes, wp_scheduled_delete).

The error is occurring every single time wp-cron.php is accessed.

See: http://wordpress.org/support/topic/387647

I can repro it as well."	defect (bug)	closed	normal	3.0	General	3.0	normal	fixed		
