Clean up some database domain ID related code and fix some comments
authorAaron Schulz <aschulz@wikimedia.org>
Fri, 29 Mar 2019 21:30:21 +0000 (14:30 -0700)
committerAaron Schulz <aschulz@wikimedia.org>
Fri, 29 Mar 2019 21:30:21 +0000 (14:30 -0700)
Change-Id: Id5c5640e05301161dbb7c2be363e32d7d1c9a511

includes/DefaultSettings.php
includes/api/ApiQuerySiteinfo.php
includes/interwiki/Interwiki.php

index 3a040c8..f16b8cb 100644 (file)
@@ -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.
index 82a52b4..ea2f31b 100644 (file)
@@ -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' );
index 832883b..30826d4 100644 (file)
@@ -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;