Comparison

core/componentmanager.lua @ 1168:dd523bfc9ea9

Dropped support for resource based components
author Waqas Hussain <waqas20@gmail.com>
date Sat, 16 May 2009 02:07:27 +0500
parent 1100:05d209ef9661
child 1177:97ecfcec2d71
comparison
equal deleted inserted replaced
1167:5620ea24be94 1168:dd523bfc9ea9
65 eventmanager.add_event_hook("server-starting", load_enabled_components); 65 eventmanager.add_event_hook("server-starting", load_enabled_components);
66 66
67 function handle_stanza(origin, stanza) 67 function handle_stanza(origin, stanza)
68 local node, host = jid_split(stanza.attr.to); 68 local node, host = jid_split(stanza.attr.to);
69 local component = nil; 69 local component = nil;
70 if not component then component = components[stanza.attr.to]; end -- hack to allow hooking node@server/resource and server/resource
71 if not component then component = components[node.."@"..host]; end -- hack to allow hooking node@server 70 if not component then component = components[node.."@"..host]; end -- hack to allow hooking node@server
72 if not component then component = components[host]; end 71 if not component then component = components[host]; end
73 if component then 72 if component then
74 log("debug", "%s stanza being handled by component: %s", stanza.name, host); 73 log("debug", "%s stanza being handled by component: %s", stanza.name, host);
75 component(origin, stanza, hosts[host]); 74 component(origin, stanza, hosts[host]);