X-Git-Url: http://git.heureux-cyclage.org/?a=blobdiff_plain;f=maintenance%2FupdateCollation.php;h=9bcba7e34400b6fb4ccb5fb43429313f6ea97ba5;hb=e65f8ac5110804067366f9f239c13f4f29b66c3d;hp=ebace75eab45f383b2a14f9ffdd151dd6b272183;hpb=af7ae6c804be8629fe2305e3a088f03e1af2fa9b;p=lhc%2Fweb%2Fwiklou.git diff --git a/maintenance/updateCollation.php b/maintenance/updateCollation.php index ebace75eab..9bcba7e344 100644 --- a/maintenance/updateCollation.php +++ b/maintenance/updateCollation.php @@ -44,10 +44,10 @@ class UpdateCollation extends Maintenance { public function __construct() { parent::__construct(); - global $wgCategoryCollation; + $categoryCollation = $this->getConfig()->get( 'CategoryCollation' ); $this->addDescription( <<getDB( DB_MASTER ); $dbr = $this->getDB( DB_REPLICA ); $force = $this->getOption( 'force' ); @@ -81,7 +79,7 @@ TEXT $collationName = $this->getOption( 'target-collation' ); $collation = Collation::factory( $collationName ); } else { - $collationName = $wgCategoryCollation; + $collationName = $this->getConfig()->get( 'CategoryCollation' ); $collation = Collation::singleton(); } @@ -104,9 +102,8 @@ TEXT 'STRAIGHT_JOIN' // per T58041 ]; - if ( $force ) { - $collationConds = []; - } else { + $collationConds = []; + if ( !$force ) { if ( $this->hasOption( 'previous-collation' ) ) { $collationConds['cl_collation'] = $this->getOption( 'previous-collation' ); } else {