# HG changeset patch # User Waqas Hussain # Date 1294190167 -18000 # Node ID 2e8411f6cb146f3c967507bb207cfd9605daf7f1 # Parent ca91d6e1d802ea56d1c133c7ddf306514f6d4f60 configmanager: Added rawget(). diff -r ca91d6e1d802 -r 2e8411f6cb14 core/configmanager.lua --- a/core/configmanager.lua Tue Jan 04 21:38:14 2011 +0000 +++ b/core/configmanager.lua Wed Jan 05 06:16:07 2011 +0500 @@ -47,6 +47,15 @@ end return nil; end +function _M.rawget(host, section, key) + local hostconfig = rawget(config, host); + if hostconfig then + local sectionconfig = rawget(hostconfig, section); + if sectionconfig then + return rawget(sectionconfig, key); + end + end +end local function set(config, host, section, key, value) if host and section and key then