Skip to content

Drop legacy quantumrpg/divinity dual-namespace permission shim - #326

Open
Travja wants to merge 2 commits into
devfrom
split/01-permissions-cleanup
Open

Drop legacy quantumrpg/divinity dual-namespace permission shim#326
Travja wants to merge 2 commits into
devfrom
split/01-permissions-cleanup

Conversation

@Travja

@Travja Travja commented Jul 23, 2026

Copy link
Copy Markdown
Contributor

Split out of #320 (piece 1/12, independent).

Perms.has() accepted both the quantumrpg.* and divinity.* namespaces as equivalent, but the plugin only ever grants quantumrpg.* nodes (Perms.PREFIX). This replaces all call sites with the plain Permissible#hasPermission() check.

No behavior change for servers using the standard quantumrpg.* permissions.

Backward compatibility

plugin.yml's divinity.* permission declarations are kept unchanged — they already alias to quantumrpg.* via Bukkit's native permission children mechanism (granting divinity.x automatically implies quantumrpg.x), which is exactly the signal the simplified Java code now checks. Any server whose permission plugin grants divinity.* nodes directly keeps working with zero config changes required.

claude added 2 commits July 23, 2026 04:23
Perms.has() accepted both the quantumrpg.* and divinity.* namespaces
as equivalent, but the plugin only ever grants quantumrpg.* nodes
(Perms.PREFIX). Replace all call sites with the plain
Permissible#hasPermission() check and remove the now-unused
divinity.* permission declarations from plugin.yml that existed
solely to back the removed shim.
The previous commit dropped both the Perms.has() dual-namespace
shim AND the divinity.* permission declarations in plugin.yml,
which would have broken any server whose permission plugin grants
divinity.* nodes directly instead of quantumrpg.* ones.

plugin.yml's divinity.* entries already alias to quantumrpg.* via
Bukkit's native permission `children` mechanism (granting divinity.x
automatically implies quantumrpg.x) — the same signal path the
Java code now checks directly via Permissible#hasPermission(). Keep
those declarations in plugin.yml unchanged; only the Java call sites
change from the custom Perms.has() shim to native hasPermission().
This keeps existing divinity.* grants working with zero runtime cost
and no admin action required.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants