From 86d7eeb4d337aa0f34b597b433b12c9c70dd543b Mon Sep 17 00:00:00 2001 From: Alexandre Emsenhuber Date: Wed, 5 Jan 2011 15:50:34 +0000 Subject: [PATCH] Easier method (and to check existence in correct language) --- includes/parser/Parser.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/includes/parser/Parser.php b/includes/parser/Parser.php index 0ef79c9a4b..a6fe0a972b 100644 --- a/includes/parser/Parser.php +++ b/includes/parser/Parser.php @@ -4097,9 +4097,9 @@ class Parser { # whatever crap the system uses, localised or not, so we cannot # ship premade translations. $key = 'timezone-' . strtolower( trim( $tzMsg ) ); - $value = wfMsgForContent( $key ); - if ( !wfEmptyMsg( $key, $value ) ) { - $tzMsg = $value; + $msg = wfMessage( $key )->inContentLanguage(); + if ( $msg->exists() ) { + $tzMsg = $msg->text(); } date_default_timezone_set( $oldtz ); -- 2.20.1