Fri, 02 Oct 2020 17:02:37 +0200
plugins/groupchat.lua: Add support for muc passwords
plugins/groupchat.lua | file | annotate | diff | comparison | revisions |
--- a/plugins/groupchat.lua Tue Sep 22 14:59:25 2020 +0200 +++ b/plugins/groupchat.lua Fri Oct 02 17:02:37 2020 +0200 @@ -27,9 +27,9 @@ end); end - function bot:join_room(room_jid, nick) + function bot:join_room(room_jid, nick, password) nick = nick or bot.config.nick or ("bot"..math.random(10000,99999)); - local room = bot.stream:join_room(room_jid, nick) + local room = bot.stream:join_room(room_jid, nick, password) room.bot = bot; room:hook("message", function(event) if event.nick == room.nick then