--- a/plugins/muc/muc.lib.lua Sun Oct 18 12:26:53 2009 +0100
+++ b/plugins/muc/muc.lib.lua Sun Oct 18 16:45:56 2009 +0500
@@ -253,7 +253,7 @@
self:broadcast_presence(pr, from);
else -- change nick
local occupant = self._occupants[current_nick];
- local is_multisession = next(occupant, next(occupant));
+ local is_multisession = next(occupant.sessions, next(occupant.sessions));
if self._occupants[to] or is_multisession then
log("debug", "%s couldn't change nick", current_nick);
local reply = st.error_reply(stanza, "cancel", "conflict"):up();