This repository was archived by the owner on Jan 20, 2022. It is now read-only.

Description
When sending mails using the contrib.EmailNotifications package, the connection to the email backend is not being closed. Most EmailBackends will provide a fallback for this issue, but some don't.
In case of Django Naomi this results in the webbrowser not being opened to preview the created email.
Steps to reproduce:
- Setup django forms
- Choose django naomi as e-mail backend
- Configure and send a form
No errors are thrown, but now browser will be opened too.
The connection is openened at:
The connection should be closed after this step:
|
connection.send_messages(emails) |
More info on opening/closing connection:
https://docs.djangoproject.com/en/3.1/topics/email/#sending-multiple-emails