From: Kim Alvefur Date: Sat, 28 May 2016 10:37:51 +0000 (+0200) Subject: MUC: Allow members (or above) in members-only non-anonymous rooms to see the member... X-Git-Url: https://git.enpas.org/?a=commitdiff_plain;h=95cb46e9925fbe50a88d0e69292e79491c00de2f;hp=ca89661ee941cad918b19714a2b6d4d70be58b45;p=prosody.git MUC: Allow members (or above) in members-only non-anonymous rooms to see the member list (fixes #445) --- diff --git a/plugins/muc/muc.lib.lua b/plugins/muc/muc.lib.lua index 88ee43c1..4018489a 100644 --- a/plugins/muc/muc.lib.lua +++ b/plugins/muc/muc.lib.lua @@ -803,7 +803,8 @@ function room_mt:handle_to_room(origin, stanza) -- presence changes and groupcha local _aff = item.attr.affiliation; local _rol = item.attr.role; if _aff and not _rol then - if affiliation == "owner" or (affiliation == "admin" and _aff ~= "owner" and _aff ~= "admin") then + if affiliation == "owner" or (affiliation == "admin" and _aff ~= "owner" and _aff ~= "admin") + or (affiliation and affiliation ~= "outcast" and self:get_members_only() and self:get_whois() == "anyone") then local reply = st.reply(stanza):query("http://jabber.org/protocol/muc#admin"); for jid, affiliation in pairs(self._affiliations) do if affiliation == _aff then