mirror of
https://github.com/TotalFreedomMC/TF-EssentialsX.git
synced 2025-04-27 17:09:43 +00:00
Null check in new player teleport, fixes #1212
This commit is contained in:
parent
719539d63b
commit
ef49d92c49
1 changed files with 5 additions and 1 deletions
|
@ -85,7 +85,11 @@ public class EssentialsSpawnPlayerListener extends PlayerListener
|
||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
user.getTeleport().now(spawns.getSpawn(ess.getSettings().getNewbieSpawn()), false, TeleportCause.PLUGIN);
|
Location spawn = spawns.getSpawn(ess.getSettings().getNewbieSpawn());
|
||||||
|
if (spawn != null)
|
||||||
|
{
|
||||||
|
user.getTeleport().now(spawn, false, TeleportCause.PLUGIN);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
catch (Exception ex)
|
catch (Exception ex)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue