2 local full_sessions = full_sessions;
3 local bare_sessions = bare_sessions;
5 module:hook("iq/full", function(data)
6 -- IQ to full JID recieved
7 local origin, stanza = data.origin, data.stanza;
9 local session = full_sessions[stanza.attr.to];
11 -- TODO fire post processing event
14 else -- resource not online
19 module:hook("iq/bare", function(data)
20 -- IQ to bare JID recieved
21 local origin, stanza = data.origin, data.stanza;
23 -- TODO if not user exists, return an error
24 -- TODO fire post processing events
25 -- TODO fire event with the xmlns:tag of the child, or with the id of errors and results
28 module:hook("iq/host", function(data)
29 -- IQ to a local host recieved
30 local origin, stanza = data.origin, data.stanza;
32 -- TODO fire event with the xmlns:tag of the child, or with the id of errors and results