aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGravatar jesopo2019-01-29 07:32:25 +0000
committerGravatar jesopo2019-01-29 07:32:25 +0000
commit66b2ffee6816be80d42cce56f84a238dfa39c6fc (patch)
tree3c82ab4c2d0c308dcaa4263e00182960883395f9
parentWe don't need a seperate command for `!channelset` override (set.py) (diff)
signature
Support `*` as a channel permission, to give users all access
(channel_access.py)
-rw-r--r--modules/channel_access.py7
1 files changed, 4 insertions, 3 deletions
diff --git a/modules/channel_access.py b/modules/channel_access.py
index f7ba7aae..ce00da0c 100644
--- a/modules/channel_access.py
+++ b/modules/channel_access.py
@@ -11,10 +11,11 @@ class Module(ModuleManager.BaseModule):
"access", [])
identified_account = event["user"].get_identified_account()
- if not require_access in access or not identified_account:
- return "You do not have permission to do this"
- else:
+ if ((require_access in acess or "*" in access) and
+ identified_account):
return utils.consts.PERMISSION_FORCE_SUCCESS
+ else:
+ return "You do not have permission to do this"
@utils.hook("received.command.access", min_args=1, channel_only=True)
def access(self, event):