Software / code / prosody
Changeset
10431:3db8372e203c 0.11
MUC: Keep role across nickname change (fixes #1466)
| author | Kim Alvefur <zash@zash.se> |
|---|---|
| date | Sat, 23 Nov 2019 01:05:28 +0100 |
| parents | 10410:659b577f280c |
| children | 10432:7b5a3de26f57 |
| 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 Sat Nov 16 16:45:33 2019 +0100 +++ b/plugins/muc/muc.lib.lua Sat Nov 23 01:05:28 2019 +0100 @@ -524,6 +524,9 @@ log("debug", "no occupant found for %s; creating new occupant object for %s", dest_jid, real_jid); is_first_dest_session = true; dest_occupant = self:new_occupant(bare_jid, dest_jid); + if orig_occupant then + dest_occupant.role = orig_occupant.role; + end else is_first_dest_session = false; end