Check if owner is set before syphoning
This commit is contained in:
parent
48622bf2e7
commit
a35aced93a
|
@ -60,6 +60,10 @@ public class ItemBindable extends Item implements IBindable
|
||||||
{
|
{
|
||||||
IBindable itemBindable = (IBindable) stack.getItem();
|
IBindable itemBindable = (IBindable) stack.getItem();
|
||||||
String owner = itemBindable.getOwnerUUID(stack);
|
String owner = itemBindable.getOwnerUUID(stack);
|
||||||
|
|
||||||
|
if (Strings.isNullOrEmpty(owner))
|
||||||
|
return false;
|
||||||
|
|
||||||
SoulNetwork network = NetworkHelper.getSoulNetwork(owner);
|
SoulNetwork network = NetworkHelper.getSoulNetwork(owner);
|
||||||
return NetworkHelper.syphonAndDamage(network, player, lpUsed);
|
return NetworkHelper.syphonAndDamage(network, player, lpUsed);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue