Skip to content

Commit

Permalink
Use Player#updateCommands instead of resendPackets
Browse files Browse the repository at this point in the history
Rebased JorelAli#471 into runtime registering (JorelAli#417)
  • Loading branch information
willkroboth committed Jul 26, 2023
1 parent 06e9c21 commit 2c86bd1
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -463,7 +463,7 @@ public void postCommandRegistration(RegisteredCommand registeredCommand, Literal

// Sending command dispatcher packets usually happens when Players join the server
for(Player p: Bukkit.getOnlinePlayers()) {
resendPackets(p);
p.updateCommands();
}
}
}
Expand Down Expand Up @@ -514,7 +514,7 @@ public void unregister(String commandName, boolean force) {
getHelpMap().remove("/" + commandName);

for (Player p : Bukkit.getOnlinePlayers()) {
resendPackets(p);
p.updateCommands();
}
}
}
Expand Down

0 comments on commit 2c86bd1

Please sign in to comment.