[email] Shorter way to raise an exception

This commit is contained in:
maike 2020-07-12 16:50:28 +02:00 committed by dl6tom
parent ecba2fb595
commit 668b702735

View file

@ -44,9 +44,7 @@ class EmailBot(Censor):
body=message.text,
)
except (ConnectionRefusedError, SMTPException):
logger.error(
"Sending subscription confirmation email failed.", exc_info=True
)
logger.exception("Sending subscription confirmation email failed.")
spawner = Spawner(Email, EmailBot)