aboutsummaryrefslogtreecommitdiffstats
path: root/wee_slack.py
diff options
context:
space:
mode:
authorRyan Huber <rhuber@gmail.com>2015-05-27 08:23:24 -0700
committerRyan Huber <rhuber@gmail.com>2015-05-27 08:23:24 -0700
commitf4384af0f7b934c3dfe5889febeb0337680c836b (patch)
tree88642a1951b8f9d1071c1b14b410ac397054d3f0 /wee_slack.py
parent192414233e03e4dd1a36c2a05f8612e247aefbdc (diff)
downloadwee-slack-f4384af0f7b934c3dfe5889febeb0337680c836b.tar.gz
more reaction fixes - don't show reactions to chans i'm not in
Diffstat (limited to 'wee_slack.py')
-rw-r--r--wee_slack.py18
1 files changed, 9 insertions, 9 deletions
diff --git a/wee_slack.py b/wee_slack.py
index 58b93b5..a4089b7 100644
--- a/wee_slack.py
+++ b/wee_slack.py
@@ -559,16 +559,16 @@ class Channel(SlackThing):
w.buffer_set(self.channel_buffer, "short_name", color + new_name)
def buffer_prnt_changed(self, user, text, time, append=""):
- if user:
- if self.server.users.find(user):
- name = self.server.users.find(user).formatted_name()
+ if self.channel_buffer:
+ if user:
+ if self.server.users.find(user):
+ name = self.server.users.find(user).formatted_name()
+ else:
+ name = user
+ name = name.decode('utf-8')
+ modify_buffer_line(self.channel_buffer, name, text, time, append)
else:
- name = user
- name = name.decode('utf-8')
- modify_buffer_line(self.channel_buffer, name, text, time, append)
- else:
- modify_buffer_line(self.channel_buffer, None, text, time, append)
- return False
+ modify_buffer_line(self.channel_buffer, None, text, time, append)
def buffer_prnt(self, user='unknown user', message='no message', time=0):
set_read_marker = False