diff --git a/kibicara/kibicara_mda.py b/kibicara/kibicara_mda.py index ef19796..5e0dd9f 100644 --- a/kibicara/kibicara_mda.py +++ b/kibicara/kibicara_mda.py @@ -47,4 +47,6 @@ async def main(): 'author': mail.get_unixfrom(), 'secret': email_row.secret, } - requests.post('http://localhost:8000/api/hoods/%d/email/messages/' % (hood.id), data=body) + requests.post( + 'http://localhost:8000/api/hoods/%d/email/messages/' % (hood.id), data=body + ) diff --git a/kibicara/platforms/email/webapi.py b/kibicara/platforms/email/webapi.py index 5961712..5ea204d 100644 --- a/kibicara/platforms/email/webapi.py +++ b/kibicara/platforms/email/webapi.py @@ -158,7 +158,9 @@ async def email_message_create( logger.warning(str(message)) logger.warning(str(email_row)) if message.secret != email_row.secret: - logger.warning("Someone is trying to submit an email without the correct API secret") + logger.warning( + "Someone is trying to submit an email without the correct API secret" + ) raise HTTPException(status_code=status.HTTP_401_UNAUTHORIZED) # pass message.text to bot.py if await spawner.get(email_row).publish(Message(message.text)):