mirror of
https://hub.spigotmc.org/stash/scm/spigot/craftbukkit.git
synced 2025-08-31 22:30:15 +00:00
SPIGOT-4478: NPE during PlayerLoginEvent recipe manipulation
This commit is contained in:
parent
3697ec7a60
commit
1663a63de2
1 changed files with 8 additions and 0 deletions
|
@ -17,3 +17,11 @@
|
||||||
this.a(minecraftkey);
|
this.a(minecraftkey);
|
||||||
this.c(minecraftkey);
|
this.c(minecraftkey);
|
||||||
arraylist.add(minecraftkey);
|
arraylist.add(minecraftkey);
|
||||||
|
@@ -61,6 +62,7 @@
|
||||||
|
}
|
||||||
|
|
||||||
|
private void a(PacketPlayOutRecipes.Action packetplayoutrecipes_action, EntityPlayer entityplayer, List<MinecraftKey> list) {
|
||||||
|
+ if (entityplayer.playerConnection == null) return; // SPIGOT-4478 during PlayerLoginEvent
|
||||||
|
entityplayer.playerConnection.sendPacket(new PacketPlayOutRecipes(packetplayoutrecipes_action, list, Collections.emptyList(), this.c, this.d, this.e, this.f));
|
||||||
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue