forked from jeremylvln/Shulker
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(shulker-proxy-agent): grant all permissions to network admins
- Loading branch information
1 parent
cafc0cb
commit 0f96077
Showing
6 changed files
with
55 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
4 changes: 4 additions & 0 deletions
4
packages/shulker-proxy-agent/src/common/kotlin/io/shulkermc/proxyagent/Configuration.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
15 changes: 15 additions & 0 deletions
15
...oxy-agent/src/velocity/kotlin/io/shulkermc/proxyagent/velocity/AdminPermissionProvider.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
package io.shulkermc.proxyagent.velocity | ||
|
||
import com.velocitypowered.api.permission.PermissionFunction | ||
import com.velocitypowered.api.permission.PermissionProvider | ||
import com.velocitypowered.api.permission.PermissionSubject | ||
import com.velocitypowered.api.permission.Tristate | ||
|
||
class AdminPermissionProvider : PermissionProvider, PermissionFunction { | ||
companion object { | ||
val INSTANCE = AdminPermissionProvider() | ||
} | ||
|
||
override fun createFunction(subject: PermissionSubject?): PermissionFunction = this | ||
override fun getPermissionValue(permission: String?): Tristate = Tristate.TRUE | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters