mirror of
https://github.com/MassiveCraft/Factions.git
synced 2024-11-27 20:59:16 +01:00
fix for rare case where faction home location's world being removed or renamed (world with specified name not existing) could lead to NPE
This commit is contained in:
parent
1459c9c057
commit
c32736f3f1
@ -75,7 +75,7 @@ public class Faction extends Entity implements EconomyParticipator
|
|||||||
}
|
}
|
||||||
public void confirmValidHome()
|
public void confirmValidHome()
|
||||||
{
|
{
|
||||||
if (!Conf.homesMustBeInClaimedTerritory || this.home == null || Board.getFactionAt(new FLocation(this.home.getLocation())) == this)
|
if (!Conf.homesMustBeInClaimedTerritory || this.home == null || (this.home.getLocation() != null && Board.getFactionAt(new FLocation(this.home.getLocation())) == this))
|
||||||
return;
|
return;
|
||||||
|
|
||||||
msg("<b>Your faction home has been un-set since it is no longer in your territory.");
|
msg("<b>Your faction home has been un-set since it is no longer in your territory.");
|
||||||
|
Loading…
Reference in New Issue
Block a user