From 798d3d048aa9e18e5cef145e0f78fcbd6e426955 Mon Sep 17 00:00:00 2001 From: Aaron Schulz Date: Fri, 29 Mar 2019 14:30:21 -0700 Subject: [PATCH] Clean up some database domain ID related code and fix some comments Change-Id: Id5c5640e05301161dbb7c2be363e32d7d1c9a511 --- includes/DefaultSettings.php | 2 +- includes/api/ApiQuerySiteinfo.php | 2 +- includes/interwiki/Interwiki.php | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/includes/DefaultSettings.php b/includes/DefaultSettings.php index 3a040c8e5d..f16b8cbed2 100644 --- a/includes/DefaultSettings.php +++ b/includes/DefaultSettings.php @@ -749,7 +749,7 @@ $wgUploadDialog = [ * - a) Whether it is fully qualified or wiki-relative. * By default, the paths of files are relative to the current wiki, * which works via prefixing them with the current wiki ID when accessed. - * Setting 'wikiId' forces the backend to be fully qualified by prefixing + * Setting 'domainId' forces the backend to be fully qualified by prefixing * all paths with the specified value instead. This can be useful if * multiple wikis need to share the same data. Note that 'name' is *not* * part of any prefix and thus should not be relied upon for namespacing. diff --git a/includes/api/ApiQuerySiteinfo.php b/includes/api/ApiQuerySiteinfo.php index 82a52b40be..ea2f31b761 100644 --- a/includes/api/ApiQuerySiteinfo.php +++ b/includes/api/ApiQuerySiteinfo.php @@ -236,7 +236,7 @@ class ApiQuerySiteinfo extends ApiQueryBase { $data[ApiResult::META_BC_BOOLS][] = 'variantarticlepath'; $data['server'] = $config->get( 'Server' ); $data['servername'] = $config->get( 'ServerName' ); - $data['wikiid'] = wfWikiID(); + $data['wikiid'] = WikiMap::getWikiIdFromDbDomain( WikiMap::getCurrentWikiDbDomain() ); $data['time'] = wfTimestamp( TS_ISO_8601, time() ); $data['misermode'] = (bool)$config->get( 'MiserMode' ); diff --git a/includes/interwiki/Interwiki.php b/includes/interwiki/Interwiki.php index 832883b806..30826d4c2a 100644 --- a/includes/interwiki/Interwiki.php +++ b/includes/interwiki/Interwiki.php @@ -36,7 +36,7 @@ class Interwiki { protected $mAPI; /** @var string The name of the database (for a connection to be established - * with LBFactory::getMainLB( 'wikiid' )) + * with LBFactory::getMainLB( 'domainId' )) */ protected $mWikiID; -- 2.20.1