Skip to content

Commit

Permalink
fix: craftings null message on disable
Browse files Browse the repository at this point in the history
  • Loading branch information
b0ykoe committed Aug 19, 2022
1 parent 5c2bc3c commit d102fd7
Showing 1 changed file with 9 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,15 @@ public void removeUser(UUID uuid) {
}

public void purgeUsers() {
if(!this.users.isEmpty()) {
this.users.values().forEach(user -> removeUser(user.getUuid()));
if (this.users == null) {
return;
}
if (this.users.isEmpty()) {
return;
}
for (Iterator<User> iterator = this.users.values().iterator(); iterator.hasNext(); ) {
User value = iterator.next();
this.users.remove(value);
}
}

Expand Down

0 comments on commit d102fd7

Please sign in to comment.