Merge "Replace wfGetLB"
authorjenkins-bot <jenkins-bot@gerrit.wikimedia.org>
Fri, 4 May 2018 19:08:32 +0000 (19:08 +0000)
committerGerrit Code Review <gerrit@wikimedia.org>
Fri, 4 May 2018 19:08:32 +0000 (19:08 +0000)
1  2 
includes/DefaultSettings.php
tests/parser/ParserTestRunner.php

@@@ -1919,8 -1919,8 +1919,8 @@@ $wgSQLiteDataDir = ''
   * $wgSharedSchema is the table schema for the shared database. It defaults to
   * $wgDBmwschema.
   *
-  * @deprecated since 1.21 In new code, use the $wiki parameter to wfGetLB() to
-  *   access remote databases. Using wfGetLB() allows the shared database to
+  * @deprecated since 1.21 In new code, use the $wiki parameter to LBFactory::getMainLB() to
+  *   access remote databases. Using LBFactory::getMainLB() allows the shared database to
   *   reside on separate servers to the wiki's own database, with suitable
   *   configuration of $wgLBFactoryConf.
   */
@@@ -3372,12 -3372,23 +3372,12 @@@ $wgApiFrameOptions = 'DENY'
   */
  $wgDisableOutputCompression = false;
  
 -/**
 - * Abandoned experiment with HTML5-style ID escaping. Normalized IDs a bit
 - * too aggressively, breaking preexisting content (particularly Cite).
 - * See T29733, T29694, T29474.
 - *
 - * @deprecated since 1.30, use $wgFragmentMode
 - */
 -$wgExperimentalHtmlIds = false;
 -
  /**
   * How should section IDs be encoded?
   * This array can contain 1 or 2 elements, each of them can be one of:
   * - 'html5'  is modern HTML5 style encoding with minimal escaping. Displays Unicode
   *            characters in most browsers' address bars.
   * - 'legacy' is old MediaWiki-style encoding, e.g. 啤酒 turns into .E5.95.A4.E9.85.92
 - * - 'html5-legacy' corresponds to DEPRECATED $wgExperimentalHtmlIds mode. DO NOT use
 - *            it for anything but migration off that mode (see below).
   *
   * The first element of this array specifies the primary mode of escaping IDs. This
   * is what users will see when they e.g. follow an [[#internal link]] to a section of
@@@ -271,6 -271,7 +271,6 @@@ class ParserTestRunner 
                $setup['wgNoFollowLinks'] = true;
                $setup['wgNoFollowDomainExceptions'] = [ 'no-nofollow.org' ];
                $setup['wgExternalLinkTarget'] = false;
 -              $setup['wgExperimentalHtmlIds'] = false;
                $setup['wgLocaltimezone'] = 'UTC';
                $setup['wgHtml5'] = true;
                $setup['wgDisableLangConversion'] = false;
                $teardown[] = $this->markSetupDone( 'setupDatabase' );
  
                # CREATE TEMPORARY TABLE breaks if there is more than one server
-               if ( wfGetLB()->getServerCount() != 1 ) {
+               if ( MediaWikiServices::getInstance()->getDBLoadBalancer()->getServerCount() != 1 ) {
                        $this->useTemporaryTables = false;
                }