Skip to content

Commit

Permalink
refractor banuser endpoint
Browse files Browse the repository at this point in the history
  • Loading branch information
tadhgboyle committed Oct 24, 2021
1 parent 3175009 commit dcbf93f
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions modules/Core/includes/endpoints/BanUserEndpoint.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,8 @@ public function execute(Nameless2API $api) {

$user = $api->getUser('id', $_POST['id']);

DB::getInstance()->update('users', $user->data()->id, [
$user->update([
'isbanned' => 1,
'active' => 0
]);

DB::getInstance()->delete('users_session', [
Expand Down

0 comments on commit dcbf93f

Please sign in to comment.