Prevent NPEs from happening

This commit is contained in:
Acrobot 2013-03-25 19:41:49 +01:00
parent cad73243a5
commit c29c132c58

View File

@ -14,7 +14,7 @@ public class ItemMoveListener implements Listener {
@EventHandler
public static void onItemMove(InventoryMoveItemEvent event) {
if (!(event.getSource().getHolder() instanceof Chest)) {
if (event.getSource() == null || !(event.getSource().getHolder() instanceof Chest)) {
return;
}