Commit d9ea3973 authored by Carsten  Rose's avatar Carsten Rose
Browse files

Sendmail.php: fix that created and modified will be written to MailLog

parent fd68e46f
......@@ -60,7 +60,6 @@ class Sendmail {
$header = $this->buildHeader($mailarr);
if (!(mb_send_mail($mailarr[SENDMAIL_IDX_RECEIVER], $mailarr[SENDMAIL_IDX_SUBJECT], $addBody . $mailarr[SENDMAIL_IDX_BODY], $header, "-f " . $mailarr[SENDMAIL_IDX_SENDER]))) {
throw new UserFormException("Error sendmail failed.", ERROR_SENDMAIL);
}
......@@ -120,7 +119,7 @@ class Sendmail {
$log[7] = empty($mailarr[SENDMAIL_IDX_SRC]) ? 0 : $mailarr[SENDMAIL_IDX_SRC];
$db = new Database();
$db->sql('INSERT INTO MailLog (`receiver`, `sender`, `subject`, `body`, `header`, `grId`, `xId`, `src`) VALUES ( ?, ? ,?, ?, ? ,?, ?, ? )', ROW_REGULAR, $log);
$db->sql('INSERT INTO MailLog (`receiver`, `sender`, `subject`, `body`, `header`, `grId`, `xId`, `src`, `modified`, `created`) VALUES ( ?, ? ,?, ?, ? ,?, ?, ?, NOW(), NOW() )', ROW_REGULAR, $log);
}
}
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment