dépôts
/
lhc
/
web
/
wiklou.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Mass conversion of $wgContLang to service
[lhc/web/wiklou.git]
/
includes
/
collation
/
Collation.php
diff --git
a/includes/collation/Collation.php
b/includes/collation/Collation.php
index
30cae5a
..
25b3d94
100644
(file)
--- a/
includes/collation/Collation.php
+++ b/
includes/collation/Collation.php
@@
-20,6
+20,8
@@
* @file
*/
* @file
*/
+use MediaWiki\MediaWikiServices;
+
/**
* @since 1.16.3
* @author Tim Starling
/**
* @since 1.16.3
* @author Tim Starling
@@
-46,13
+48,12
@@
abstract class Collation {
* @return Collation
*/
public static function factory( $collationName ) {
* @return Collation
*/
public static function factory( $collationName ) {
- global $wgContLang;
-
switch ( $collationName ) {
case 'uppercase':
return new UppercaseCollation;
case 'numeric':
switch ( $collationName ) {
case 'uppercase':
return new UppercaseCollation;
case 'numeric':
- return new NumericUppercaseCollation( $wgContLang );
+ return new NumericUppercaseCollation(
+ MediaWikiServices::getInstance()->getContentLanguage() );
case 'identity':
return new IdentityCollation;
case 'uca-default':
case 'identity':
return new IdentityCollation;
case 'uca-default':
@@
-63,14
+64,10
@@
abstract class Collation {
return new CollationCkb;
case 'xx-uca-et':
return new CollationEt;
return new CollationCkb;
case 'xx-uca-et':
return new CollationEt;
- case 'xx-uca-fa':
- return new CollationFa;
case 'uppercase-ab':
return new AbkhazUppercaseCollation;
case 'uppercase-ba':
return new BashkirUppercaseCollation;
case 'uppercase-ab':
return new AbkhazUppercaseCollation;
case 'uppercase-ba':
return new BashkirUppercaseCollation;
- case 'uppercase-se':
- return new NorthernSamiUppercaseCollation;
default:
$match = [];
if ( preg_match( '/^uca-([A-Za-z@=-]+)$/', $collationName, $match ) ) {
default:
$match = [];
if ( preg_match( '/^uca-([A-Za-z@=-]+)$/', $collationName, $match ) ) {