Extra checks on method to get ready for our bungeecord addon

Former-commit-id: f6eb6a0facc99fbc14db4a411cd70f8333d78566
This commit is contained in:
Ghost_chu committed 2020-03-15 09:24:01 +08:00
1 parent 37deba95ef
commit 4d76ee8d2c
1 file changed
+3
@@ -385,6 +385,9 @@ public class ShopManager {
}
public void handleChat(@NotNull Player p, @NotNull String msg, boolean bypassProtectionChecks) {
if (!plugin.getShopManager().getActions().containsKey(p.getUniqueId())) {
return;
}
final String message = ChatColor.stripColor(msg);
// Use from the main thread, because Bukkit hates life
Bukkit.getScheduler().scheduleSyncDelayedTask(plugin, () -> {