mirror of
https://github.com/TotalFreedomMC/TF-EssentialsX.git
synced 2024-08-20 18:32:49 +00:00
Fix null locations in /seen
This commit is contained in:
parent
45de85dae2
commit
055603b09e
|
@ -116,6 +116,7 @@ public class EssentialsPlayerListener implements Listener
|
|||
{
|
||||
user.toggleGodModeEnabled();
|
||||
}
|
||||
user.setLastLocation();
|
||||
user.updateActivity(false);
|
||||
user.dispose();
|
||||
}
|
||||
|
|
|
@ -60,7 +60,9 @@ public class Commandseen extends EssentialsCommand
|
|||
{
|
||||
sender.sendMessage(_("whoisIPAddress", player.getLastLoginAddress()));
|
||||
final Location loc = player.getLastLocation();
|
||||
sender.sendMessage(_("whoisLocation", loc.getWorld().getName(), loc.getBlockX(), loc.getBlockY(), loc.getBlockZ()));
|
||||
if (loc != null) {
|
||||
sender.sendMessage(_("whoisLocation", loc.getWorld().getName(), loc.getBlockX(), loc.getBlockY(), loc.getBlockZ()));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue