Software /
code /
prosody
Changeset
3606:c52b06de9b27
componentmanager: Removed.
author | Waqas Hussain <waqas20@gmail.com> |
---|---|
date | Wed, 10 Nov 2010 21:48:28 +0500 |
parents | 3605:b8208f5e612a |
children | 3607:e1259b6d7560 |
files | core/componentmanager.lua |
diffstat | 1 files changed, 0 insertions(+), 36 deletions(-) [+] |
line wrap: on
line diff
--- a/core/componentmanager.lua Wed Nov 10 21:47:39 2010 +0500 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,36 +0,0 @@ --- Prosody IM --- Copyright (C) 2008-2010 Matthew Wild --- Copyright (C) 2008-2010 Waqas Hussain --- --- This project is MIT/X11 licensed. Please see the --- COPYING file in the source package for more information. --- - -local log = require "util.logger".init("componentmanager"); -local prosody, hosts = prosody, prosody.hosts; - -local components = {}; - -module "componentmanager" - -function register_component(host, component) - if hosts[host] and hosts[host].type == 'component' then - components[host] = component; - log("debug", "component added: "..host); - return hosts[host]; - else - log("error", "Attempt to set component for existing host: "..host); - end -end - -function deregister_component(host) - if components[host] then - components[host] = nil; - log("debug", "component removed: "..host); - return true; - else - log("error", "Attempt to remove component for non-existing host: "..host); - end -end - -return _M;