diff --git a/plugin.py b/plugin.py index 94adebe..cfa9a9d 100644 --- a/plugin.py +++ b/plugin.py @@ -248,9 +248,11 @@ class Keycloak(callbacks.Plugin): print(url) usergroups = response.json() if usergroups: + groups = [] for group in usergroups: groupname = group['name'] - irc.reply(groupname) + groups.append(groupname) + irc.replies(groups, prefixer='Group(s): ', joiner=', ', onlyPrefixFirst=True) else: irc.reply("No groups.") except: @@ -287,9 +289,11 @@ class Keycloak(callbacks.Plugin): print(url) usergroups = response.json() if usergroups: + groups = [] for group in usergroups: groupname = group['name'] - irc.reply(groupname) + groups.append(groupname) + irc.replies(groups, prefixer='Group(s): ', joiner=', ', onlyPrefixFirst=True) else: irc.reply("No groups.") except: