revoke_super_admin

revoke_super_admin

Appears in: , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , ,
Hook Type: action
See hook in action

See hook in core

Displaying hooks found in version: wordpress-6.7.1

do_action('revoke_super_admin') is found 1 times:

  • /wp-includes/capabilities.php line 1250
    	 * @since 3.0.0
    	 *
    	 * @param int $user_id ID of the user Super Admin privileges are being revoked from.
    	 */
    	do_action( 'revoke_super_admin', $user_id );
    
    	// Directly fetch site_admins instead of using get_super_admins().
    	$super_admins = get_site_option( 'site_admins', array( 'admin' ) );
    
    	$user = get_userdata( $user_id );
    	if ( $user && 0 !== strcasecmp( $user->user_email, get_site_option( 'admin_email' ) ) ) {
    

See this hook used in plugins: