wpseek.com
A WordPress-centric search engine for devs and theme authors



wp_roles › WordPress Function

Since4.3.0
Deprecatedn/a
wp_roles ( No parameters )
Returns:
  • (WP_Roles) WP_Roles global instance if not already instantiated.
Defined at:
Codex:

Retrieves the global WP_Roles instance and instantiates it if necessary.



Related Functions: wp_styles, wp_rss, wp_robots, wp_kses, wp_cron

Source

function wp_roles() {
	global $wp_roles;

	if ( ! isset( $wp_roles ) ) {
		$wp_roles = new WP_Roles();
	}
	return $wp_roles;
}