mirror of
https://github.com/EssentialsX/Essentials.git
synced 2024-12-23 17:47:34 +01:00
Fix for an error in checkFullUserPermission caused by players
disconnecting mid perms update.
This commit is contained in:
parent
87ccd7bf46
commit
5560ab4294
@ -69,4 +69,4 @@ v 1.5:
|
||||
If the files have been altered (on disc) it will reload, so long as the in-memory data hasn't changed.
|
||||
If the files on Disc have changed AND there have been changes to it's in-memory data it will show a warning.
|
||||
You then MUST issue a '/mansave force' to overwrite the disc files, or a '/manload' to overwrite the memory data.
|
||||
- Fix for an error in checkFullUserPermission caused by silly requests for a null perm.
|
||||
- Fix for an error in checkFullUserPermission caused by players disconnecting mid perms update.
|
@ -658,7 +658,7 @@ public class AnjoPermissionsHandler extends PermissionsReaderInterface {
|
||||
if (result.resultType.equals(PermissionCheckResult.Type.EXCEPTION) || result.resultType.equals(PermissionCheckResult.Type.FOUND)) {
|
||||
return true;
|
||||
}
|
||||
if (Bukkit.getPlayer(user.getName()).hasPermission(permission))
|
||||
if ((Bukkit.getPlayer(user.getName()) != null) && (Bukkit.getPlayer(user.getName()).hasPermission(permission)))
|
||||
return true;
|
||||
|
||||
return false;
|
||||
@ -700,7 +700,7 @@ public class AnjoPermissionsHandler extends PermissionsReaderInterface {
|
||||
}
|
||||
}
|
||||
|
||||
if (Bukkit.getPlayer(user.getName()).hasPermission(targetPermission)) {
|
||||
if ((Bukkit.getPlayer(user.getName()) != null) && (Bukkit.getPlayer(user.getName()).hasPermission(targetPermission))) {
|
||||
result.resultType = PermissionCheckResult.Type.FOUND;
|
||||
result.owner = user;
|
||||
return result;
|
||||
|
Loading…
Reference in New Issue
Block a user