mirror of
https://github.com/Pathduck/gallery3.git
synced 2026-07-25 17:24:10 -04:00
Fix a bug that I think I introduced in my last sendmail refactor where
I inverted the expectations on the result from mail() causing image uploads to fail (even though the mail gets sent!)
This commit is contained in:
@@ -83,7 +83,7 @@ class Sendmail_Core {
|
||||
// need to use a single \n. This can be set in config/sendmail.php
|
||||
$headers = implode($this->header_separator, $headers);
|
||||
$message = wordwrap($this->message, $this->line_length, "\n");
|
||||
if ($this->mail($to, $this->subject, $message, $headers)) {
|
||||
if (!$this->mail($to, $this->subject, $message, $headers)) {
|
||||
Kohana::log("error", wordwrap("Sending mail failed:\nTo: $to\n $this->subject\n" .
|
||||
"Headers: $headers\n $this->message"));
|
||||
throw new Exception("@todo SEND MAIL FAILED");
|
||||
|
||||
Reference in New Issue
Block a user