From 0f3ce8022f9ee23c9af712bdc23c28c4dea1d9cc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nikola=20Forr=C3=B3?= Date: Sun, 29 Apr 2018 19:20:04 +0200 Subject: [PATCH] Fix debug mode detection --- bot.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/bot.py b/bot.py index cc0a411..fd974a4 100644 --- a/bot.py +++ b/bot.py @@ -17,9 +17,7 @@ config.read('settings.cfg') log = logging.getLogger('irc.client') log.addHandler(logging.StreamHandler()) - -if os.getenv('DEBUG', False): - log.setLevel(logging.DEBUG) +log.setLevel(logging.DEBUG if bool(int(os.getenv('DEBUG', 0))) else logging.INFO) QUOTE_ADDED_PATTERN = re.compile(r'''^