Software /
code /
prosody
Comparison
plugins/mod_pubsub/mod_pubsub.lua @ 6843:161cccfdf015
Merge 0.10->trunk
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Tue, 22 Sep 2015 01:31:52 +0200 |
parent | 6666:42fdc8dddf04 |
parent | 6841:be87ab2d611c |
child | 7717:9c8eb0239eef |
comparison
equal
deleted
inserted
replaced
6839:298182fd2387 | 6843:161cccfdf015 |
---|---|
26 function handle_pubsub_iq(event) | 26 function handle_pubsub_iq(event) |
27 local origin, stanza = event.origin, event.stanza; | 27 local origin, stanza = event.origin, event.stanza; |
28 local pubsub = stanza.tags[1]; | 28 local pubsub = stanza.tags[1]; |
29 local action = pubsub.tags[1]; | 29 local action = pubsub.tags[1]; |
30 if not action then | 30 if not action then |
31 return origin.send(st.error_reply(stanza, "cancel", "bad-request")); | 31 origin.send(st.error_reply(stanza, "cancel", "bad-request")); |
32 return true; | |
32 end | 33 end |
33 local handler = handlers[stanza.attr.type.."_"..action.name]; | 34 local handler = handlers[stanza.attr.type.."_"..action.name]; |
34 if handler then | 35 if handler then |
35 handler(origin, stanza, action, service); | 36 handler(origin, stanza, action, service); |
36 return true; | 37 return true; |