On this page
do_action( 'remove_user_role', int $user_id, string $role )
Fires immediately after a role as been removed from a user.
Parameters
$user_idint-
The user ID.
$rolestring-
The removed role.
Source
File: wp-includes/class-wp-user.php. View all references
do_action( 'remove_user_role', $this->ID, $role );
Related
Used By
| Used By | Description |
|---|---|
| WP_User::remove_role() wp-includes/class-wp-user.php | Removes role from user. |
| WP_User::set_role() wp-includes/class-wp-user.php | Sets the role of the user. |
Changelog
| Version | Description |
|---|---|
| 4.3.0 | Introduced. |
© 2003–2022 WordPress Foundation
Licensed under the GNU GPLv2+ License.
https://developer.wordpress.org/reference/hooks/remove_user_role