Software /
code /
prosody
Comparison
core/moduleapi.lua @ 5530:d83482fc4a81
moduleapi: in module:provides(), add the name of the module in item._provided_by
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Sat, 27 Apr 2013 19:44:37 +0200 |
parent | 5529:af58eea131b4 |
child | 5771:c4ed6680bf8d |
comparison
equal
deleted
inserted
replaced
5529:af58eea131b4 | 5530:d83482fc4a81 |
---|---|
333 if item_name:find(name.."_", 1, true) == 1 then | 333 if item_name:find(name.."_", 1, true) == 1 then |
334 item_name = item_name:sub(#name+2); | 334 item_name = item_name:sub(#name+2); |
335 end | 335 end |
336 item.name = item_name; | 336 item.name = item_name; |
337 end | 337 end |
338 item._provided_by = self.name; | |
338 self:add_item(name.."-provider", item); | 339 self:add_item(name.."-provider", item); |
339 end | 340 end |
340 | 341 |
341 function api:send(stanza) | 342 function api:send(stanza) |
342 return core_post_stanza(hosts[self.host], stanza); | 343 return core_post_stanza(hosts[self.host], stanza); |