diff options
Diffstat (limited to 'browse_slack')
-rw-r--r-- | browse_slack/convert_slack.py | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/browse_slack/convert_slack.py b/browse_slack/convert_slack.py index ad9e9789..57be3681 100644 --- a/browse_slack/convert_slack.py +++ b/browse_slack/convert_slack.py @@ -45,12 +45,11 @@ user_id = {} # name -> index length = 0 with open('users.json') as f: for user in json.load(f): - if user['id'] not in user_id: - if 'real_name' not in user: - user['real_name'] = '' - print(f"({json.dumps(user['id'])} \"@{user['name']}\" {json.dumps(user['real_name'])} [{look_up_ppm_image(user['profile']['image_72']) or ''}])") - user_id[user['id']] = length - length += 1 + if 'real_name' not in user: + user['real_name'] = '' + print(f"({json.dumps(user['id'])} \"@{user['name']}\" {json.dumps(user['real_name'])} [{look_up_ppm_image(user['profile']['image_72']) or ''}])") + user_id[user['id']] = length + length += 1 items = [] |