Don't pass a MailAddress pass the email to mail()
authorReedy <reedy@wikimedia.org>
Sat, 20 Oct 2018 12:37:15 +0000 (13:37 +0100)
committerReedy <reedy@wikimedia.org>
Sat, 20 Oct 2018 20:44:17 +0000 (20:44 +0000)
Bug: T207541
Change-Id: I1516023907e9773cb093010c6b67279f695abb1a
(cherry picked from commit c57aacb782f5ce5e53253192a53d736ece300d3c)

RELEASE-NOTES-1.31
includes/mail/UserMailer.php

index e8c384a..2245aba 100644 (file)
@@ -15,6 +15,7 @@ THIS IS NOT A RELEASE YET
   not be set.
 * Fix PHP 7.3 warnings "preg_replace(): [...] invalid range in character class"
 * (T207540) Include IP address in "Login for $1 succeeded" log entry.
+* (T207541) Pass email address to mail().
 
 == MediaWiki 1.31.1 ==
 
index bdd4f44..fcb6173 100644 (file)
@@ -431,7 +431,7 @@ class UserMailer {
                        try {
                                foreach ( $to as $recip ) {
                                        $sent = mail(
-                                               $recip,
+                                               $recip->toString(),
                                                self::quotedPrintable( $subject ),
                                                $body,
                                                $headers,