From 3501f4f0c9b95e1061c1b6f94ab46b3bbebb05e3 Mon Sep 17 00:00:00 2001 From: Waqas Hussain Date: Fri, 12 Nov 2010 23:35:02 +0500 Subject: mod_component: Use module:get_option() instead of configmanager. --- plugins/mod_component.lua | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/plugins/mod_component.lua b/plugins/mod_component.lua index b2c571d3..a5192e8c 100644 --- a/plugins/mod_component.lua +++ b/plugins/mod_component.lua @@ -14,7 +14,6 @@ local hosts = _G.hosts; local t_concat = table.concat; -local config = require "core.configmanager"; local sha1 = require "util.hashes".sha1; local st = require "util.stanza"; @@ -68,7 +67,7 @@ function handle_component_auth(event) return true; end - local secret = config.get(session.host, "core", "component_secret"); + local secret = module:get_option("component_secret"); if not secret then (session.log or log)("warn", "Component attempted to identify as %s, but component_secret is not set", session.host); session:close("not-authorized"); -- cgit v1.2.3