aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTrygve Aaberge <trygveaa@gmail.com>2020-05-22 21:40:08 +0200
committerTrygve Aaberge <trygveaa@gmail.com>2020-05-22 23:52:19 +0200
commit87480a91372c7f893e08fbde6b46981bac14636a (patch)
tree89d2aaea2cb5ead8a9840939848ba3ee79166033
parente76d20c5125bd01af81555b9cbdd16e9c3d5d9b5 (diff)
downloadwee-slack-87480a91372c7f893e08fbde6b46981bac14636a.tar.gz
Use user instead of slack_name for users.info
users.info takes the id, not the name of the user. This worked in practice before this change because it was only called for unknown users, and unknown users gets the name set to the id.
-rw-r--r--wee_slack.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/wee_slack.py b/wee_slack.py
index d29627d..ee0e8bd 100644
--- a/wee_slack.py
+++ b/wee_slack.py
@@ -2068,7 +2068,7 @@ class SlackDMChannel(SlackChannel):
def set_related_server(self, team):
super(SlackDMChannel, self).set_related_server(team)
if self.user not in self.team.users:
- s = SlackRequest(self.team, 'users.info', {'user': self.slack_name}, channel=self)
+ s = SlackRequest(self.team, 'users.info', {'user': self.user}, channel=self)
self.eventrouter.receive(s)
def create_buffer(self):