* updated statuses logic;

This commit is contained in:
Mykyta Synelnikov
2024-09-30 23:10:15 +03:00
parent 67ea631681
commit 6f9be57495
3 changed files with 12 additions and 3 deletions
+5 -1
View File
@@ -43,7 +43,11 @@ class Users {
$actions['put_user_as_pending'] = array( 'label' => __( 'Put as Pending Review', 'ultimate-member' ) );
}
if ( UM()->common()->users()->can_activation_send( $user_id ) ) {
$actions['resend_user_activation'] = array( 'label' => __( 'Resend Activation Email', 'ultimate-member' ) );
$title = __( 'Send activation email', 'ultimate-member' );
if ( UM()->common()->users()->has_status( $user_id, 'awaiting_email_confirmation' ) ) {
$title = __( 'Resend activation email', 'ultimate-member' );
}
$actions['resend_user_activation'] = array( 'label' => $title );
}
if ( UM()->common()->users()->can_be_deactivated( $user_id ) ) {
$actions['deactivate_user'] = array( 'label' => __( 'Deactivate this account', 'ultimate-member' ) );