# HG changeset patch # User Dennis Fink # Date 2015-10-25 22:25:25 # Node ID 3d53c627707a65bc94f875e3675f1c11edd8f409 # Parent b5c3362767729bd85f43cfab757340cebcc6cce6 Disable logging when using the cli tool diff --git a/ennstatus/cli/commands/stats.py b/ennstatus/cli/commands/stats.py --- a/ennstatus/cli/commands/stats.py +++ b/ennstatus/cli/commands/stats.py @@ -35,7 +35,7 @@ def count(obj, by_type): app = create_app() with app.app_context(): - app.logger.removeHandler(app.logger.handlers[1]) + app.logger.disabled = True servers = split_all_servers_to_types() if not by_type: @@ -66,7 +66,7 @@ def countries(obj, by_type): app = create_app() with app.app_context(): - app.logger.removeHandler(app.logger.handlers[1]) + app.logger.disabled = True servers = split_all_servers_to_types() if not by_type: