new_user_approve_$status_user

Perform an action when a user’s status is updated to a specific action. $status will be either approve or deny.

1
2
3
4
function deny_user( $user_id ) {
    wp_delete_user( $user_id );
}
add_action( 'new_user_approve_deny_user', 'deny_user' );
Scroll to Top