diff -r dffbb7d1da4b -r 89e9f0d555a2 core/stanza_router.lua --- a/core/stanza_router.lua Sun May 17 04:50:32 2009 +0500 +++ b/core/stanza_router.lua Tue May 19 01:07:03 2009 +0500 @@ -123,7 +123,9 @@ local to_bare = node and (node.."@"..host) or host; -- bare JID local event_data = {origin=origin, stanza=stanza}; - if fire_event(tostring(host or origin.host).."/"..stanza.name, event_data) then + if host and fire_event(host.."/"..stanza.name, event_data) then + -- event handled + elseif stanza.name == "presence" and origin.host and fire_event(origin.host.."/"..stanza.name, event_data) then -- event handled elseif not to then modules_handle_stanza(host or origin.host or origin.to_host, origin, stanza);