Changeset

6128:8a71a1c34202

plugins/muc/muc.lib: Use occupant jids when whois == "moderators"
author daurnimator <quae@daurnimator.com>
date Wed, 19 Mar 2014 17:50:49 -0400
parents 6127:a66ebc5d0ab5
children 6129:6c66571ab0f9
files plugins/muc/muc.lib.lua
diffstat 1 files changed, 3 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/plugins/muc/muc.lib.lua	Wed Mar 19 17:50:00 2014 -0400
+++ b/plugins/muc/muc.lib.lua	Wed Mar 19 17:50:49 2014 -0400
@@ -992,6 +992,9 @@
 	end
 	local _invitee = jid_prep(payload.attr.to);
 	if _invitee then
+		if self:get_whois() == "moderators" then
+			_from = current_nick;
+		end
 		local _reason = payload:get_child_text("reason")
 		local invite = st.message({from = _to, to = _invitee, id = stanza.attr.id})
 			:tag('x', {xmlns='http://jabber.org/protocol/muc#user'})