From: Platonides Date: Sat, 4 Jun 2011 21:19:07 +0000 (+0000) Subject: Follow up r60599. Make normalizeUnicode() work even if $wgContLang is still not set, X-Git-Tag: 1.31.0-rc.0~29714 X-Git-Url: http://git.cyclocoop.org/%22%2C%20generer_url_ecrire%28?a=commitdiff_plain;h=923f44359bc6fd95985616cd5d4223150deb383b;p=lhc%2Fweb%2Fwiklou.git Follow up r60599. Make normalizeUnicode() work even if $wgContLang is still not set, just as it did before (eg. getGPCVal() check). This allows for early calls before MediaWiki is completely initialised. --- diff --git a/includes/WebRequest.php b/includes/WebRequest.php index 9ede547dd9..53881efc37 100644 --- a/includes/WebRequest.php +++ b/includes/WebRequest.php @@ -227,7 +227,7 @@ class WebRequest { } } else { global $wgContLang; - $data = $wgContLang->normalize( $data ); + $data = isset( $wgContLang ) ? $wgContLang->normalize( $data ) : UtfNormal::cleanUp( $data ); } return $data; }