equal
deleted
inserted
replaced
271 local room = get_room_from_jid(room_jid); |
271 local room = get_room_from_jid(room_jid); |
272 if room == nil then |
272 if room == nil then |
273 -- Watch presence to create rooms |
273 -- Watch presence to create rooms |
274 if stanza.attr.type == nil and stanza.name == "presence" then |
274 if stanza.attr.type == nil and stanza.name == "presence" then |
275 room = muclib.new_room(room_jid); |
275 room = muclib.new_room(room_jid); |
|
276 return room:handle_first_presence(origin, stanza); |
276 elseif stanza.attr.type ~= "error" then |
277 elseif stanza.attr.type ~= "error" then |
277 origin.send(st.error_reply(stanza, "cancel", "not-allowed")); |
278 origin.send(st.error_reply(stanza, "cancel", "not-allowed")); |
278 return true; |
279 return true; |
279 else |
280 else |
280 return; |
281 return; |