equal
deleted
inserted
replaced
24 local origin, stanza = event.origin, event.stanza; |
24 local origin, stanza = event.origin, event.stanza; |
25 local orig_type = stanza.attr.type or "normal"; |
25 local orig_type = stanza.attr.type or "normal"; |
26 local orig_from = stanza.attr.from; |
26 local orig_from = stanza.attr.from; |
27 local orig_to = stanza.attr.to; |
27 local orig_to = stanza.attr.to; |
28 |
28 |
29 if not(orig_type == "chat" or orig_type == "normal" and stanza:get_child("body")) then |
29 if not(orig_type == "chat" or (orig_type == "normal" and stanza:get_child("body"))) then |
30 return -- Only chat type messages |
30 return -- Only chat type messages |
31 end |
31 end |
32 |
32 |
33 -- Stanza sent by a local client |
33 -- Stanza sent by a local client |
34 local bare_jid = jid_bare(orig_from); |
34 local bare_jid = jid_bare(orig_from); |