mirror of
https://github.com/TotalFreedomMC/TF-EssentialsX.git
synced 2025-01-03 22:08:28 +00:00
Fix NPE in UserData#getHome (#4234)
This commit is contained in:
parent
c43af5d3d9
commit
3fe279e229
1 changed files with 2 additions and 1 deletions
|
@ -155,7 +155,8 @@ public abstract class UserData extends PlayerExtension implements IConf {
|
|||
|
||||
public Location getHome(final String name) throws Exception {
|
||||
final String search = getHomeName(name);
|
||||
return holder.homes().get(search).location();
|
||||
final LazyLocation loc = holder.homes().get(search);
|
||||
return loc != null ? loc.location() : null;
|
||||
}
|
||||
|
||||
public Location getHome(final Location world) {
|
||||
|
|
Loading…
Reference in a new issue