Comparison

plugins/mod_dialback.lua @ 4584:9a5de6509aa8

mod_s2s, mod_dialback: Event on pre-XMPP streams, so we can try dialback.
author Kim Alvefur <zash@zash.se>
date Sat, 03 Mar 2012 01:35:39 +0100
parent 4579:5650c290fe8e
child 4586:4d63852910ff
comparison
equal deleted inserted replaced
4583:6f2789939d35 4584:9a5de6509aa8
158 initiate_dialback(origin); 158 initiate_dialback(origin);
159 return true; 159 return true;
160 end 160 end
161 end, 100); 161 end, 100);
162 162
163 module:hook("s2s-no-stream-features", function (event)
164 initiate_dialback(event.origin);
165 return true;
166 end, 100);
167
163 -- Offer dialback to incoming hosts 168 -- Offer dialback to incoming hosts
164 module:hook("s2s-stream-features", function (data) 169 module:hook("s2s-stream-features", function (data)
165 data.features:tag("dialback", { xmlns='urn:xmpp:features:dialback' }):up(); 170 data.features:tag("dialback", { xmlns='urn:xmpp:features:dialback' }):up();
166 end); 171 end);