update unsuspend console command to use set_unsuspended user method

This commit is contained in:
Kareila 2023-06-11 22:02:34 +00:00
parent ceff4547c8
commit a408b974d3
1 changed files with 2 additions and 3 deletions

View File

@ -106,11 +106,10 @@ sub execute {
next;
}
$u->update_self( { statusvis => 'V', raw => 'statusvisdate=NOW()' } );
my $err;
$self->error($err) unless $u->set_unsuspended( $remote, $reason, \$err );
$u->{statusvis} = 'V';
LJ::statushistory_add( $u, $remote, "unsuspend", $reason );
$self->print("User '$username' unsuspended.");
}