diff --git a/app/email.py b/app/email.py index 88effaf9f68640b18ea267d79a4ffb174eead0ab..b6dd4e4e67a66371cc0153d7c0571670cd59c08a 100644 --- a/app/email.py +++ b/app/email.py @@ -16,6 +16,7 @@ def create_message(recipient, subject, template, **kwargs): @background -def send(app, msg): +def send(msg, *args, **kwargs): + app = kwargs['app'] with app.app_context(): mail.send(msg)