Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement a restrictions for commands #11

Closed
purrplingcat opened this issue Jul 24, 2017 · 0 comments
Closed

Implement a restrictions for commands #11

purrplingcat opened this issue Jul 24, 2017 · 0 comments
Milestone

Comments

@purrplingcat
Copy link
Owner

purrplingcat commented Jul 24, 2017

Checking user is allowed for exec command now is defined by flag 'restricted'

cmd = {
  "description": "Admin cmd",
  "usage": "<user>",
  "botAdminOnly": false
  "restrictions:" "MSG_EDIT"
}

This command CAN run only user with permision MSG_EDIT. You can define mopre restrictions via Array: [ "KICK_MEMBERS", "BAN_MEMBERS" ]

If flag botAdminOnly is true, then command can run only user who's a BOT ADMINISTRATOR. This flag overrides restrictions definition.

Commands, who is for @everyone has set 'restricted' to FALSE or has not set it.

@purrplingcat purrplingcat changed the title Implement a restricted flag for commands Implement a restrictions for commands Sep 24, 2017
@purrplingcat purrplingcat added this to the 1.4.0-rc milestone Oct 24, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant