From: Michael Date: Thu, 13 Jun 2019 03:22:15 +0000 (+0000) Subject: Sanitize the date for mails X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=2ae437160600efe1b262064b33e39f73360c9410;p=friendica.git Sanitize the date for mails --- diff --git a/src/Model/Mail.php b/src/Model/Mail.php index 30191edae6..9f3682573e 100644 --- a/src/Model/Mail.php +++ b/src/Model/Mail.php @@ -46,6 +46,8 @@ class Mail $msg['guid'] = Item::guidFromUri($msg['uri'], $host); } + $msg['created'] = (isset($msg['created']) ? DateTimeFormat::utc($msg['created']) : DateTimeFormat::utcNow()); + DBA::lock('mail'); if (DBA::exists('mail', ['uri' => $msg['uri'], 'uid' => $msg['uid']])) {