diff options
| author | 2019-05-09 11:55:35 +0100 | |
|---|---|---|
| committer | 2019-05-09 11:55:35 +0100 | |
| commit | 5dd019d79f587cce5de0ff5fae94faaa39f5a34d (patch) | |
| tree | a8348c8a69c51e75bcbe974752eaff0184bc8d43 /modules | |
| parent | Only split NAMES reply at literal space, .split() is overzealous (diff) | |
| signature | ||
Handle dangling spaces at the end of a NAMES response
Diffstat (limited to 'modules')
| -rw-r--r-- | modules/line_handler/channel.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/modules/line_handler/channel.py b/modules/line_handler/channel.py index 6976fcc1..0f0858c6 100644 --- a/modules/line_handler/channel.py +++ b/modules/line_handler/channel.py @@ -30,6 +30,11 @@ def handle_333(events, event): def handle_353(event): channel = event["server"].channels.get(event["args"][2]) nicknames = event["args"].get(3).split(" ") + + # there can sometimes be a dangling space at the end of a 353 + if nicknames and not nicknames[-1]: + nicknames.pop(-1) + for nickname in nicknames: modes = set([]) |
