# HG changeset patch # User Waqas Hussain # Date 1294867870 -18000 # Node ID 0c9399a66b17e15fcd5a989c845f7c024727cea5 # Parent b42ca82b0ea4076772146d7a3beffeb5ccabdf24 loggingmanager: Re-read 'debug' option on reload. diff -r b42ca82b0ea4 -r 0c9399a66b17 core/loggingmanager.lua --- a/core/loggingmanager.lua Tue Jan 11 22:40:09 2011 +0000 +++ b/core/loggingmanager.lua Thu Jan 13 02:31:10 2011 +0500 @@ -27,8 +27,6 @@ local logger = require "util.logger"; local prosody = prosody; -local debug_mode = config.get("*", "core", "debug"); - _G.log = logger.init("general"); module "loggingmanager" @@ -166,6 +164,8 @@ logger.reset(); + local debug_mode = config.get("*", "core", "debug"); + default_logging = { { to = "console" , levels = { min = (debug_mode and "debug") or "info" } } }; default_file_logging = { { to = "file", levels = { min = (debug_mode and "debug") or "info" }, timestamps = true }