Comparison

plugins/muc/mod_muc.lua @ 1780:668ce0a2050d

MUC: Added a send() method to the component. Fixes issues with local mod_vcard.
author Waqas Hussain <waqas20@gmail.com>
date Mon, 14 Sep 2009 02:08:20 +0500
parent 1767:649dd3439809
child 1781:b3eee6151592
comparison
equal deleted inserted replaced
1779:3da808c7bfa2 1780:668ce0a2050d
121 return; 121 return;
122 end 122 end
123 -- to the main muc domain 123 -- to the main muc domain
124 handle_to_domain(origin, stanza); 124 handle_to_domain(origin, stanza);
125 end); 125 end);
126 function component.send(stanza) -- FIXME do a generic fix
127 if stanza.attr.type == "result" or stanza.attr.type == "error" then
128 core_post_stanza(component, stanza);
129 else error("component.send only supports result and error stanzas at the moment"); end
130 end
126 131
127 prosody.hosts[module:get_host()].muc = { rooms = rooms }; 132 prosody.hosts[module:get_host()].muc = { rooms = rooms };
128 133
129 module.unload = function() 134 module.unload = function()
130 deregister_component(muc_host); 135 deregister_component(muc_host);