Software / code / prosody
Comparison
plugins/mod_pubsub.lua @ 5308:fd3219d64414
mod_pubsub: Ignore subscription options for now, fixes traceback due to missing form
| author | Kim Alvefur <zash@zash.se> |
|---|---|
| date | Thu, 24 Jan 2013 16:36:48 +0100 |
| parent | 5305:391b72fede9f |
| child | 5312:fdcd2ac7c22d |
comparison
equal
deleted
inserted
replaced
| 5307:d80e56d8805c | 5308:fd3219d64414 |
|---|---|
| 109 return origin.send(reply); | 109 return origin.send(reply); |
| 110 end | 110 end |
| 111 | 111 |
| 112 function handlers.set_subscribe(origin, stanza, subscribe) | 112 function handlers.set_subscribe(origin, stanza, subscribe) |
| 113 local node, jid = subscribe.attr.node, subscribe.attr.jid; | 113 local node, jid = subscribe.attr.node, subscribe.attr.jid; |
| 114 --[[ | |
| 114 local options_tag, options = stanza.tags[1]:get_child("options"), nil; | 115 local options_tag, options = stanza.tags[1]:get_child("options"), nil; |
| 115 if options_tag then | 116 if options_tag then |
| 116 options = options_form:data(options_tag.tags[1]); | 117 options = options_form:data(options_tag.tags[1]); |
| 117 end | 118 end |
| 119 --]] | |
| 120 local options_tag, options; -- FIXME | |
| 118 local ok, ret = service:add_subscription(node, stanza.attr.from, jid, options); | 121 local ok, ret = service:add_subscription(node, stanza.attr.from, jid, options); |
| 119 local reply; | 122 local reply; |
| 120 if ok then | 123 if ok then |
| 121 reply = st.reply(stanza) | 124 reply = st.reply(stanza) |
| 122 :tag("pubsub", { xmlns = xmlns_pubsub }) | 125 :tag("pubsub", { xmlns = xmlns_pubsub }) |