Mercurial > prosody-hg
comparison plugins/mod_muc.lua @ 856:946d0f91bd38
mod_muc: Don't bounce error replies in response to errors
| author | Matthew Wild <mwild1@gmail.com> |
|---|---|
| date | Mon, 02 Mar 2009 19:50:28 +0000 |
| parents | 2a8bfb7dee77 |
| children | 2189baddedb8 |
comparison
equal
deleted
inserted
replaced
| 855:57057f2cbecb | 856:946d0f91bd38 |
|---|---|
| 285 end | 285 end |
| 286 end | 286 end |
| 287 elseif type ~= 'result' then -- bad type | 287 elseif type ~= 'result' then -- bad type |
| 288 origin.send(st.error_reply(stanza, "modify", "bad-request")); -- FIXME correct error? | 288 origin.send(st.error_reply(stanza, "modify", "bad-request")); -- FIXME correct error? |
| 289 end | 289 end |
| 290 elseif not current_nick then -- not in room | 290 elseif not current_nick and type ~= "error" then -- not in room |
| 291 origin.send(st.error_reply(stanza, "cancel", "not-acceptable")); | 291 origin.send(st.error_reply(stanza, "cancel", "not-acceptable")); |
| 292 elseif stanza.name == "message" and type == "groupchat" then -- groupchat messages not allowed in PM | 292 elseif stanza.name == "message" and type == "groupchat" then -- groupchat messages not allowed in PM |
| 293 origin.send(st.error_reply(stanza, "modify", "bad-request")); | 293 origin.send(st.error_reply(stanza, "modify", "bad-request")); |
| 294 elseif stanza.name == "message" and type == "error" then | 294 elseif stanza.name == "message" and type == "error" then |
| 295 log("debug", "%s kicked from %s for sending an error message", current_nick, room); | 295 log("debug", "%s kicked from %s for sending an error message", current_nick, room); |
