diff --git a/tsstats/__main__.py b/tsstats/__main__.py index b364e0c..2fa648a 100644 --- a/tsstats/__main__.py +++ b/tsstats/__main__.py @@ -77,10 +77,11 @@ def main(configuration): logger.setLevel(logging.DEBUG) if configuration.getboolean('General', 'debugstdout'): stream_handler.setLevel(logging.DEBUG) + else: + logger.addHandler(file_handler) # attach handlers logger.addHandler(stream_handler) - logger.addHandler(file_handler) idmap = configuration.get('General', 'idmap') if idmap: