mirror of
https://github.com/PlayPro/CoreProtect.git
synced 2024-11-24 12:16:36 +01:00
Fixed NullPointerException on Mohist servers when processing inventory transactions
This commit is contained in:
parent
e7c5078035
commit
cfb53f766e
@ -317,7 +317,12 @@ public final class InventoryChangeListener extends Queue implements Listener {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
Location location = event.getSource().getLocation();
|
Inventory sourceInventory = event.getSource();
|
||||||
|
if (sourceInventory == null) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
Location location = sourceInventory.getLocation();
|
||||||
if (location == null) {
|
if (location == null) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -327,7 +332,7 @@ public final class InventoryChangeListener extends Queue implements Listener {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
InventoryHolder sourceHolder = PaperAdapter.ADAPTER.getHolder(event.getSource(), false);
|
InventoryHolder sourceHolder = PaperAdapter.ADAPTER.getHolder(sourceInventory, false);
|
||||||
if (sourceHolder == null) {
|
if (sourceHolder == null) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user