From: Brad Jorsch Date: Mon, 9 Sep 2019 14:22:43 +0000 (-0400) Subject: maintenance/getReplicaServer.php: Remove reference to long-deleted config var X-Git-Tag: 1.34.0-rc.0~318^2 X-Git-Url: https://git.cyclocoop.org/%7B%24www_url%7Dadmin/compta/banques/Bar?a=commitdiff_plain;h=3a39f364dc3f53fcad235eeb4f878fcec16be6e4;p=lhc%2Fweb%2Fwiklou.git maintenance/getReplicaServer.php: Remove reference to long-deleted config var $wgAllDBsAreLocalhost was removed 3 years ago, in I54b23654. This maintenance script kept working because it just saw null for the variable. But then Id67d0759 changed the code to access it via Config, which does checking for accessing of nonexistent config vars and so broke things. Bug: T232268 Change-Id: I4fc39cccfd9041c76f734a1a85c2b34fc84218f0 --- diff --git a/maintenance/getReplicaServer.php b/maintenance/getReplicaServer.php index d861348dbd..7e9104ccea 100644 --- a/maintenance/getReplicaServer.php +++ b/maintenance/getReplicaServer.php @@ -38,9 +38,7 @@ class GetReplicaServer extends Maintenance { } public function execute() { - if ( $this->getConfig()->get( 'AllDBsAreLocalhost' ) ) { - $host = 'localhost'; - } elseif ( $this->hasOption( 'group' ) ) { + if ( $this->hasOption( 'group' ) ) { $db = $this->getDB( DB_REPLICA, $this->getOption( 'group' ) ); $host = $db->getServer(); } else {