joe icon indicating copy to clipboard operation
joe copied to clipboard

Allow for specifying whether message is DM in `ReceiveMessageEvent`

Open deuill opened this issue 5 years ago • 0 comments

Currently, the standard joe.ReceiveMessageEvent sent by all documented adapters does not specify whether the message is "private" (a one-on-one chat in Slack, a /msg in IRC, etc).

This can be useful in having handlers process commands differently (e.g. allow admin-level commands in direct chats) depending on the communication mode, without having to either parse the Channel or Data fields (which assumes the handler knows which adapter is being used) or having to use custom events, which assume adapter support.

deuill avatar Feb 09 '20 20:02 deuill