mirror of
https://github.com/EssentialsX/Essentials.git
synced 2024-11-18 00:25:32 +01:00
Only pull/push data on valid player data.
This commit is contained in:
parent
05242a7e8f
commit
f0c49019dd
@ -168,6 +168,7 @@ public class EssentialsPlayerListener extends PlayerListener
|
||||
{
|
||||
user.setDisplayNick(user.getNick());
|
||||
}
|
||||
user.setLastLoginAddress(user.getAddress().getAddress().getHostAddress());
|
||||
user.updateActivity(false);
|
||||
if (user.isAuthorized("essentials.sleepingignored"))
|
||||
{
|
||||
@ -231,7 +232,6 @@ public class EssentialsPlayerListener extends PlayerListener
|
||||
event.allow();
|
||||
|
||||
user.setLastLogin(System.currentTimeMillis());
|
||||
user.setLastLoginAddress(user.getAddress().getAddress().getHostAddress());
|
||||
updateCompass(user);
|
||||
}
|
||||
|
||||
|
@ -290,7 +290,7 @@ public class User extends UserData implements Comparable<User>, IReplyTo, IUser
|
||||
@Override
|
||||
public String getDisplayName()
|
||||
{
|
||||
if (ess.getSettings().changeDisplayName())
|
||||
if (!(base instanceof OfflinePlayer) && ess.getSettings().changeDisplayName())
|
||||
{
|
||||
setDisplayNick(getNick());
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user