wp_roles(): WP_Roles

Retrieves the global WP_Roles instance and instantiates it if necessary.


Return

WP_Roles WP_Roles global instance if not already instantiated.


Top ↑

Source

File: wp-includes/capabilities.php. View all references

function wp_roles() {
	global $wp_roles;

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


Top ↑

Changelog

Changelog
Version Description
4.3.0 Introduced.

Top ↑

User Contributed Notes

You must log in before being able to contribute a note or feedback.