Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

localizeddate filter : now IntlDateFormatter uses timezone from "PHP …

…ini setting", and not from "TZ environment variable" (default behavior).
  • Loading branch information...
commit 32d3eec393447aff0451425aa9cea027fdb48ce5 1 parent f904575
freepius44 authored
Showing with 2 additions and 1 deletion.
  1. +2 −1  lib/Twig/Extensions/Extension/Intl.php
View
3  lib/Twig/Extensions/Extension/Intl.php
@@ -54,7 +54,8 @@ function twig_localized_date_filter($date, $dateFormat = 'medium', $timeFormat =
$formatter = IntlDateFormatter::create(
$locale !== null ? $locale : Locale::getDefault(),
$formatValues[$dateFormat],
- $formatValues[$timeFormat]
+ $formatValues[$timeFormat],
+ date_default_timezone_get()
);
if (!$date instanceof DateTime) {
Please sign in to comment.
Something went wrong with that request. Please try again.