Commit 8bb5b606 authored by Claude Paroz's avatar Claude Paroz
Browse files

Fixed #17811 -- Added connection parameter in call to EmailMessage from...

Fixed #17811 -- Added connection parameter in call to EmailMessage from send_mass_mail. Thanks fed239 for the report and danielr for the patch.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@17827 bcc190cf-cafb-0310-a4f2-bffc1f526a37
parent 31e84e40
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -78,7 +78,8 @@ def send_mass_mail(datatuple, fail_silently=False, auth_user=None,
    connection = connection or get_connection(username=auth_user,
                                    password=auth_password,
                                    fail_silently=fail_silently)
    messages = [EmailMessage(subject, message, sender, recipient)
    messages = [EmailMessage(subject, message, sender, recipient,
                             connection=connection)
                for subject, message, sender, recipient in datatuple]
    return connection.send_messages(messages)