[email] Shorter way to raise an exception
This commit is contained in:
parent
ecba2fb595
commit
668b702735
|
@ -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)
|
||||
|
|
Loading…
Reference in a new issue