diff options
author | Trygve Aaberge <trygveaa@gmail.com> | 2018-01-14 23:39:37 +0100 |
---|---|---|
committer | Trygve Aaberge <trygveaa@gmail.com> | 2018-01-14 23:39:37 +0100 |
commit | cfe2911d300625a3a22dd8afecb32b70eeea02d9 (patch) | |
tree | 5fa372ab7148dccd2dac87d1c5a7db51901a6ada /wee_slack.py | |
parent | 499f2c758d1fc11cacaf6db7203b64154a2547a1 (diff) | |
download | wee-slack-cfe2911d300625a3a22dd8afecb32b70eeea02d9.tar.gz |
Reload emoji list on emoji change event
It's simpler to just reload the whole list instead of adding and
removing specific emojis, especially since we would have to remove
aliases for an emoji when the emoji is removed (and we don't store if an
emoji is an alias or not).
Since this probably doesn't happen that often, it shouldn't be a problem
to do it this way.
Diffstat (limited to 'wee_slack.py')
-rw-r--r-- | wee_slack.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/wee_slack.py b/wee_slack.py index 5eee13d..94dce4c 100644 --- a/wee_slack.py +++ b/wee_slack.py @@ -2497,6 +2497,11 @@ def process_reaction_removed(message_json, eventrouter, **kwargs): else: dbg("Reaction to item type not supported: " + str(message_json)) + +def process_emoji_changed(message_json, eventrouter, **kwargs): + team = kwargs['team'] + team.load_emoji_completions() + ###### New module/global methods def render_formatting(text): |