DiscordIntegration

DiscordIntegration

3M Downloads

The MC command discord link requires OP permission

cpw opened this issue ยท 7 comments

commented

Base informations

Minecraft version:
1.12.2

DiscordIntegration version:
3.0.5

Server type and version: Forge/Spigot/Sponge
Forge

Link to pastebin with (censored) config: Optional
Nah

Expected behavior

everyone can run discord link to link themselves

Actual behavior

Only ops can run discord link to link themselves

Steps to reproduce

Run discord link on a dedicated server without op permission.

commented

As a comment: the type discrepancy between the discordChannel minecraft entry (requires a long, aka number value in the config) and the Discord channel config (strings all the way baby!) is probably a big reason most people don't get this working properly. You might want to clarify or handle the duality in code.

commented

Well this happens because the only check for permissions is for /discord, meaning the whole command (and all subcommands, including link) require OP.
See the code here.

So possible fixes would be creating a new command for link (/discordlink) or letting anyone execute the command and manage the permissions by ourself in the execute method.

commented

I really dont see why it needs a completely new config format, and I needed this for my server. ๐Ÿคทโ€โ™‚๏ธ

commented

It's not a completely new config, just some tweaks discussed in #109 and listed https://gist.github.com/Chikachi/bec420e90202a22094f4e6e7ba31999b .
Most notably I moved the "token" to another file because people often forgot to remove it there (insecure).

But yea if it works for you, that's great :-)

commented

@thiakil Now we did the same work ohw ohw :s
I am currently working on the integration of config v4 (almost done) and I also added this.
I'll push it any moment to my branch.

commented

FYI: this isn't fixed apparently. Someone tried it today. Still need OP.