add by email fails if there is more than 1 recipient.
Roznoshchik opened this issue · 1 comments
Roznoshchik commented
def add_by_email():
recipient = request.form['to']
if '<' in recipient:
recipient = recipient.split('<')[1][:-1]
This is the code being used to get the recipient of the email. When someone emails something to Lurnby and there is more than a single email in the request.form['to']
then the function fails as it isn't pulling out the right email.
A better solution would likely be to use regex to pull out the email that has @add-article.lurnby.com
as the ending.
Roznoshchik commented
This has been fixed and multiple recipients no longer cause the app to error.