mirror of
https://github.com/LuckPerms/LuckPerms.git
synced 2024-11-24 03:25:19 +01:00
Allow world rewrite options to apply in (some) Vault lookups (#990)
This commit is contained in:
parent
20f992110d
commit
1e73986c60
@ -345,9 +345,11 @@ public class VaultPermissionHook extends AbstractVaultPermission {
|
||||
context = this.plugin.getContextManager().getStaticContext().mutableCopy();
|
||||
}
|
||||
|
||||
String playerWorld = player == null ? null : player.getWorld().getName();
|
||||
|
||||
// if world is null, we want to do a lookup in the players current context
|
||||
// if world is not null, we want to do a lookup in that specific world
|
||||
if (world != null && !world.isEmpty()) {
|
||||
if (world != null && !world.isEmpty() && !world.equalsIgnoreCase(playerWorld)) {
|
||||
// remove already accumulated worlds
|
||||
context.removeAll(Contexts.WORLD_KEY);
|
||||
// add the vault world
|
||||
|
Loading…
Reference in New Issue
Block a user