wp_roles_init
Fires after the roles have been initialized, allowing plugins to add their own roles.
Usage
add_action( 'wp_roles_init', 'wp_kama_roles_init_action' ); /** * Function for `wp_roles_init` action-hook. * * @param WP_Roles $wp_roles A reference to the WP_Roles object. * * @return void */ function wp_kama_roles_init_action( $wp_roles ){ // action... }
- $wp_roles(WP_Roles)
- A reference to the WP_Roles object.
Changelog
Since 4.7.0 | Introduced. |
Where the hook is called
wp_roles_init
wp-includes/class-wp-roles.php 303
do_action( 'wp_roles_init', $this );