added a way for command event hooks to ask to only be fired from private messages.

This commit is contained in:
jesopo 2016-04-04 18:41:07 +01:00
parent d5e4c7bbe7
commit 436db4b9a8
No known key found for this signature in database
GPG key ID: 0BBDEB2AEFCFFCB3

View file

@ -86,6 +86,8 @@ class Module(object):
target = event["user"]
if not is_channel and hook.kwargs.get("channel_only"):
return
if is_channel and hooks.kwargs.get("private_only"):
return
log = target.log