Enable Telethon logging if debug is enabled

This commit is contained in:
Tulir Asokan
2018-02-03 14:05:44 +02:00
parent a35cb58ee5
commit 3c8ed4454d
+3
View File
@@ -60,6 +60,9 @@ if args.generate_registration:
sys.exit(0)
if config["appservice.debug"]:
telethon_log = logging.getLogger("telethon")
telethon_log.addHandler(handler)
telethon_log.setLevel(logging.DEBUG)
log.setLevel(logging.DEBUG)
log.debug("Debug messages enabled.")