diff options
author | Matthew Wild <mwild1@gmail.com> | 2018-05-16 23:57:30 +0100 |
---|---|---|
committer | Matthew Wild <mwild1@gmail.com> | 2018-05-16 23:57:30 +0100 |
commit | ef17c4f12cd7fdffd5a91e45bb7e5a24dd871880 (patch) | |
tree | c34e255d7770edb6ba7a2f7155f1c3b7bc4a6f90 | |
parent | 6a8358e64753fca28bcae3d85cfd6cc8560b79de (diff) | |
download | prosody-ef17c4f12cd7fdffd5a91e45bb7e5a24dd871880.tar.gz prosody-ef17c4f12cd7fdffd5a91e45bb7e5a24dd871880.zip |
MUC: Restore status codes on presence sent to occupant when their affiliation changes (thanks jonasw)
-rw-r--r-- | plugins/muc/muc.lib.lua | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/plugins/muc/muc.lib.lua b/plugins/muc/muc.lib.lua index 524cc843..a1b42c87 100644 --- a/plugins/muc/muc.lib.lua +++ b/plugins/muc/muc.lib.lua @@ -1136,9 +1136,13 @@ function room_mt:set_affiliations(actor, jid_affiliation, callback) if not role then -- getting kicked presence_type = "unavailable"; if affiliation == "outcast" then - x:tag("status", {code="301"}):up(); -- banned + -- banned + x:tag("status", {code="301"}):up(); + self_x:tag("status", {code="301"}):up(); else - x:tag("status", {code="321"}):up(); -- affiliation change + -- affiliation change + x:tag("status", {code="321"}):up(); + self_x:tag("status", {code="321"}):up(); end end for nick, occupant in pairs(self._occupants) do |