LuckPerms

LuckPerms

41.4k Downloads

IllegalArgumentException: Contexts#allowAll passed to contextual #getGraph method

Sir-Will opened this issue ยท 1 comments

commented

I updated LP to 4.4.26 recently and now I'm getting the following error:

Caused by: java.lang.IllegalArgumentException: Contexts#allowAll passed to contextual #getGraph method
	at me.lucko.luckperms.common.inheritance.InheritanceHandler.getGraph(InheritanceHandler.java:66)
	at me.lucko.luckperms.common.model.PermissionHolder.accumulateInheritancesTo(PermissionHolder.java:314)
	at me.lucko.luckperms.common.api.implementation.ApiPermissionHolder.getAllNodes(ApiPermissionHolder.java:137)

Do I need to change something in my plugin or is this a bug?

commented

Yes, if you want to use Contexts#allowAll, just use the method that doesn't accept a Contexts parameter.

So

holder.getAllNodes(Contexts.allowAll())

becomes

holder.getAllNodes()