Apply regex perms before wildcards

This commit is contained in:
Luck committed 2017-02-11 12:12:28 +00:00
1 parent 6a39b721ba
commit 140e6b08ca
3 files changed
+9 -9

No files matched your search

@@ -47,12 +47,12 @@ public class SpongeCalculatorFactory extends AbstractCalculatorFactory {
ImmutableList.Builder<PermissionProcessor> processors = ImmutableList.builder();
processors.add(new MapProcessor());
processors.add(new SpongeWildcardProcessor());
if (plugin.getConfiguration().get(ConfigKeys.APPLYING_WILDCARDS)) {
processors.add(new WildcardProcessor());
}
if (plugin.getConfiguration().get(ConfigKeys.APPLYING_REGEX)) {
processors.add(new RegexProcessor());
}
if (plugin.getConfiguration().get(ConfigKeys.APPLYING_WILDCARDS)) {
processors.add(new WildcardProcessor());
}
processors.add(new DefaultsProcessor(plugin.getService(), contexts.getContexts()));
return registerCalculator(new PermissionCalculator(plugin, user.getName(), processors.build()));