Skip to content
Snippets Groups Projects
Commit 3aae5cf1 authored by Peter Rotich's avatar Peter Rotich
Browse files

Account for ISO Date timezone indicator

parent 49900b17
No related branches found
No related tags found
No related merge requests found
......@@ -684,6 +684,8 @@ class Format {
$tz = $datetime->getTimezone()->getName();
if ($tz && $tz[0] == '+' || $tz[0] == '-')
$tz = (int) $datetime->format('Z');
elseif ($tz == 'Z')
$tz = 'UTC';
$timezone = new DateTimeZone(Format::timezone($tz) ?: 'UTC');
$datetime->setTimezone($timezone);
} catch (Exception $ex) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment