equal
deleted
inserted
replaced
131 module:log("debug", "Sending[rest]: %s", stanza:top_tag()); |
131 module:log("debug", "Sending[rest]: %s", stanza:top_tag()); |
132 response.headers.content_type = send_type; |
132 response.headers.content_type = send_type; |
133 response:send(encode(send_type, stanza)); |
133 response:send(encode(send_type, stanza)); |
134 return true; |
134 return true; |
135 end |
135 end |
136 if module:send(payload, origin) then |
136 module:send(payload, origin); |
137 return 202; |
137 return 202; |
138 else |
|
139 return 500; |
|
140 end |
|
141 end |
138 end |
142 end |
139 end |
143 |
140 |
144 -- Handle stanzas submitted via HTTP |
141 -- Handle stanzas submitted via HTTP |
145 module:depends("http"); |
142 module:depends("http"); |