diff options
author | Florian Zeitz <florob@babelmonkeys.de> | 2010-12-03 16:36:13 +0100 |
---|---|---|
committer | Florian Zeitz <florob@babelmonkeys.de> | 2010-12-03 16:36:13 +0100 |
commit | 2e85ac05dddc25aec01225933656982c9a5bcd31 (patch) | |
tree | 9595a938025541f949c42732e5b2136fb0c2fab5 /plugins | |
parent | 00171e2bb53e081c5126a080119bfbf5ccb5f805 (diff) | |
download | prosody-2e85ac05dddc25aec01225933656982c9a5bcd31.tar.gz prosody-2e85ac05dddc25aec01225933656982c9a5bcd31.zip |
mod_pubsub: Use pubsub_error_reply everywhere
Diffstat (limited to 'plugins')
-rw-r--r-- | plugins/mod_pubsub.lua | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/plugins/mod_pubsub.lua b/plugins/mod_pubsub.lua index f92d27aa..83ce0ad9 100644 --- a/plugins/mod_pubsub.lua +++ b/plugins/mod_pubsub.lua @@ -25,6 +25,7 @@ function handle_pubsub_iq(event) end local pubsub_errors = { + ["conflict"] = { "cancel", "conflict" }; ["invalid-jid"] = { "modify", "bad-request", nil, "invalid-jid" }; ["item-not-found"] = { "cancel", "item-not-found" }; }; @@ -50,7 +51,7 @@ function handlers.get_items(origin, stanza, items) :tag("pubsub", { xmlns = xmlns_pubsub }) :add_child(data); else - reply = st.error_reply(stanza, "cancel", "item-not-found", "Item could not be found in this node"); + reply = pubsub_error_reply(stanza, "item-not-found"); end return origin.send(reply); end @@ -63,7 +64,7 @@ function handlers.set_create(origin, stanza, create) if ok then reply = st.reply(stanza); else - reply = st.error_reply(stanza, "cancel", ret); + reply = pubsub_error_reply(stanza, ret); end else repeat |