Software /
code /
prosody
Comparison
core/modulemanager.lua @ 1346:e34f9455b779
modulemanager: Change the ideitity attribute typ to type
author | Waqas Hussain <waqas20@gmail.com> |
---|---|
date | Sat, 13 Jun 2009 00:07:16 +0500 |
parent | 1334:6846c5cc9ce2 |
child | 1360:857034905016 |
comparison
equal
deleted
inserted
replaced
1342:947d94e3619f | 1346:e34f9455b779 |
---|---|
365 end); | 365 end); |
366 | 366 |
367 function api:add_feature(xmlns) | 367 function api:add_feature(xmlns) |
368 features_table:set(self.host, self.name, xmlns, true); | 368 features_table:set(self.host, self.name, xmlns, true); |
369 end | 369 end |
370 function api:add_identity(category, typ) | 370 function api:add_identity(category, type) |
371 identities_table:set(self.host, self.name, category.."\0"..typ, {category = category, typ = typ}); | 371 identities_table:set(self.host, self.name, category.."\0"..type, {category = category, type = type}); |
372 end | 372 end |
373 | 373 |
374 local event_hook = function(host, mod_name, event_name, ...) | 374 local event_hook = function(host, mod_name, event_name, ...) |
375 if type((...)) == "table" and (...).host and (...).host ~= host then return; end | 375 if type((...)) == "table" and (...).host and (...).host ~= host then return; end |
376 for handler in pairs(event_hooks:get(host, mod_name, event_name) or NULL) do | 376 for handler in pairs(event_hooks:get(host, mod_name, event_name) or NULL) do |