Fix Bug#24308 where, on some platforms the date_create() function fails when the...
authorMark A. Hershberger <mah@users.mediawiki.org>
Sat, 2 Apr 2011 04:49:29 +0000 (04:49 +0000)
committerMark A. Hershberger <mah@users.mediawiki.org>
Sat, 2 Apr 2011 04:49:29 +0000 (04:49 +0000)
includes/Preferences.php

index 37563dd..fd5f233 100644 (file)
@@ -1202,7 +1202,8 @@ class Preferences {
                        $prefill = array_fill_keys( array_values( $tzRegions ), array() );
                        $opt = array_merge( $opt, $prefill );
 
-                       $now = date_create( 'now' );
+                       global $wgLocaltimezone;
+                       $now = date_create( 'now', $wgLocaltimezone );
 
                        foreach ( $tzs as $tz ) {
                                $z = explode( '/', $tz, 2 );