(bug 12608) Unifying the spelling of getDBkey() in the code.
authorHuji <huji@users.mediawiki.org>
Mon, 14 Jan 2008 09:13:04 +0000 (09:13 +0000)
committerHuji <huji@users.mediawiki.org>
Mon, 14 Jan 2008 09:13:04 +0000 (09:13 +0000)
RELEASE-NOTES
includes/AjaxFunctions.php
includes/CategoryPage.php
includes/Revision.php
includes/SearchEngine.php
includes/Skin.php
includes/SkinTemplate.php
includes/SpecialExport.php
includes/SpecialRecentchangeslinked.php
includes/SpecialUndelete.php
includes/Title.php

index 0e6a9e4..ddfb576 100644 (file)
@@ -307,6 +307,7 @@ it from source control: http://www.mediawiki.org/wiki/Download_from_SVN
 * Use only default options when generating RSS and Atom syndication links.
   This should help prevent infinite link loops that some software may follow,
   and will generally keep feed behavior cleaner.
+* (bug 12608) Unifying the spelling of getDBkey() in the code.
 
 
 == Parser changes in 1.12 ==
index 013771b..b004cfc 100644 (file)
@@ -90,7 +90,7 @@ function wfSajaxSearch( $term ) {
                $db = wfGetDB( DB_SLAVE );
                $res = $db->select( 'page', array( 'page_title', 'page_namespace' ),
                                array(  'page_namespace' => $term_title->getNamespace(),
-                                       "page_title LIKE '". $db->strencode( $term_title->getDBKey() ) ."%'" ),
+                                       "page_title LIKE '". $db->strencode( $term_title->getDBkey() ) ."%'" ),
                                        "wfSajaxSearch",
                                        array( 'LIMIT' => $limit+1 )
                                );
index 656d316..6fbcd3c 100644 (file)
@@ -215,7 +215,7 @@ class CategoryViewer {
                        array( 'page_title', 'page_namespace', 'page_len', 'page_is_redirect', 'cl_sortkey' ),
                        array( $pageCondition,
                               'cl_from          =  page_id',
-                              'cl_to'           => $this->title->getDBKey()),
+                              'cl_to'           => $this->title->getDBkey()),
                               #'page_is_redirect' => 0),
                        #+ $pageCondition,
                        __METHOD__,
index 80fc03c..05a4a68 100644 (file)
@@ -47,7 +47,7 @@ class Revision {
                        array( "rev_id=$matchId",
                               'page_id=rev_page',
                               'page_namespace' => $title->getNamespace(),
-                              'page_title'     => $title->getDbkey() ) );
+                              'page_title'     => $title->getDBkey() ) );
        }
 
        /**
@@ -110,7 +110,7 @@ class Revision {
                        array( "rev_id=$matchId",
                               'page_id=rev_page',
                               'page_namespace' => $title->getNamespace(),
-                              'page_title'     => $title->getDbkey() ) );
+                              'page_title'     => $title->getDBkey() ) );
        }
 
        /**
@@ -131,7 +131,7 @@ class Revision {
                        array( 'rev_timestamp'  => $db->timestamp( $timestamp ),
                               'page_id=rev_page',
                               'page_namespace' => $title->getNamespace(),
-                              'page_title'     => $title->getDbkey() ) );
+                              'page_title'     => $title->getDBkey() ) );
        }
 
        /**
@@ -190,7 +190,7 @@ class Revision {
                return Revision::fetchFromConds(
                        wfGetDB( DB_SLAVE ),
                        array( 'page_namespace' => $title->getNamespace(),
-                              'page_title'     => $title->getDbkey(),
+                              'page_title'     => $title->getDBkey(),
                               'page_id=rev_page' ) );
        }
 
@@ -209,7 +209,7 @@ class Revision {
                        wfGetDB( DB_SLAVE ),
                        array( 'rev_id=page_latest',
                               'page_namespace' => $title->getNamespace(),
-                              'page_title'     => $title->getDbkey(),
+                              'page_title'     => $title->getDBkey(),
                               'page_id=rev_page' ) );
        }
 
index 11fc3de..9120da5 100644 (file)
@@ -109,7 +109,7 @@ class SearchEngine {
                # Entering an IP address goes to the contributions page
                if ( ( $title->getNamespace() == NS_USER && User::isIP($title->getText() ) )
                        || User::isIP( trim( $searchterm ) ) ) {
-                       return SpecialPage::getTitleFor( 'Contributions', $title->getDbkey() );
+                       return SpecialPage::getTitleFor( 'Contributions', $title->getDBkey() );
                }
 
 
index 9d00e1d..64d8b3e 100644 (file)
@@ -310,7 +310,7 @@ class Skin extends Linker {
                        'wgScript' => $wgScript,
                        'wgServer' => $wgServer,
                        'wgCanonicalNamespace' => $nsname,
-                       'wgCanonicalSpecialPageName' => SpecialPage::resolveAlias( $wgTitle->getDBKey() ),
+                       'wgCanonicalSpecialPageName' => SpecialPage::resolveAlias( $wgTitle->getDBkey() ),
                        'wgNamespaceNumber' => $wgTitle->getNamespace(),
                        'wgPageName' => $wgTitle->getPrefixedDBKey(),
                        'wgTitle' => $wgTitle->getText(),
@@ -1069,7 +1069,7 @@ END;
                        $dbr = wfGetDB( DB_SLAVE );
                        $watchlist = $dbr->tableName( 'watchlist' );
                        $sql = "SELECT COUNT(*) AS n FROM $watchlist
-                               WHERE wl_title='" . $dbr->strencode($wgTitle->getDBKey()) .
+                               WHERE wl_title='" . $dbr->strencode($wgTitle->getDBkey()) .
                                "' AND  wl_namespace=" . $wgTitle->getNamespace() ;
                        $res = $dbr->query( $sql, 'Skin::pageStats');
                        $x = $dbr->fetchObject( $res );
index d013119..0178b86 100644 (file)
@@ -344,7 +344,7 @@ class SkinTemplate extends Skin {
                                $dbr = wfGetDB( DB_SLAVE );
                                $watchlist = $dbr->tableName( 'watchlist' );
                                $sql = "SELECT COUNT(*) AS n FROM $watchlist
-                                       WHERE wl_title='" . $dbr->strencode($this->mTitle->getDBKey()) .
+                                       WHERE wl_title='" . $dbr->strencode($this->mTitle->getDBkey()) .
                                        "' AND  wl_namespace=" . $this->mTitle->getNamespace() ;
                                $res = $dbr->query( $sql, 'SkinTemplate::outputPage');
                                $x = $dbr->fetchObject( $res );
index 12bd4d5..71eb122 100644 (file)
@@ -24,7 +24,7 @@
 function wfExportGetPagesFromCategory( $title ) {
        global $wgContLang;
 
-       $name = $title->getDBKey();
+       $name = $title->getDBkey();
 
        $dbr = wfGetDB( DB_SLAVE );
 
index ffb0a4d..9bf957f 100644 (file)
@@ -76,7 +76,7 @@ function wfSpecialRecentchangeslinked( $par = NULL ) {
 
        // If target is a Category, use categorylinks and invert from and to
        if( $nt->getNamespace() == NS_CATEGORY ) {
-               $catkey = $dbr->addQuotes( $nt->getDBKey() );
+               $catkey = $dbr->addQuotes( $nt->getDBkey() );
                $sql = "SELECT /* wfSpecialRecentchangeslinked */
                                rc_id,
                                rc_cur_id,
index 1fe11c1..a64cfc2 100644 (file)
@@ -57,7 +57,7 @@ class PageArchive {
                $title = Title::newFromText( $prefix );
                if( $title ) {
                        $ns = $title->getNamespace();
-                       $encPrefix = $dbr->escapeLike( $title->getDbKey() );
+                       $encPrefix = $dbr->escapeLike( $title->getDBkey() );
                } else {
                        // Prolly won't work too good
                        // @todo handle bare namespace names cleanly?
@@ -132,7 +132,7 @@ class PageArchive {
                                        'fa_user',
                                        'fa_user_text',
                                        'fa_timestamp' ),
-                               array( 'fa_name' => $this->title->getDbKey() ),
+                               array( 'fa_name' => $this->title->getDBkey() ),
                                __METHOD__,
                                array( 'ORDER BY' => 'fa_timestamp DESC' ) );
                        $ret = $dbr->resultObject( $res );
@@ -174,7 +174,7 @@ class PageArchive {
                                'ar_text_id',
                                'ar_len' ),
                        array( 'ar_namespace' => $this->title->getNamespace(),
-                              'ar_title' => $this->title->getDbkey(),
+                              'ar_title' => $this->title->getDBkey(),
                               'ar_timestamp' => $dbr->timestamp( $timestamp ) ),
                        __METHOD__ );
                if( $row ) {
@@ -212,7 +212,7 @@ class PageArchive {
                $row = $dbr->selectRow( 'archive',
                        'ar_timestamp',
                        array( 'ar_namespace' => $this->title->getNamespace(),
-                              'ar_title' => $this->title->getDbkey(),
+                              'ar_title' => $this->title->getDBkey(),
                               'ar_timestamp < ' .
                                                $dbr->addQuotes( $dbr->timestamp( $timestamp ) ) ),
                        __METHOD__,
@@ -225,7 +225,7 @@ class PageArchive {
                        array( 'rev_id', 'rev_timestamp' ),
                        array(
                                'page_namespace' => $this->title->getNamespace(),
-                               'page_title' => $this->title->getDbkey(),
+                               'page_title' => $this->title->getDBkey(),
                                'page_id = rev_page',
                                'rev_timestamp < ' .
                                                $dbr->addQuotes( $dbr->timestamp( $timestamp ) ) ),
index 18e87ce..32f6575 100644 (file)
@@ -1263,7 +1263,7 @@ class Title {
 
                $dbr = wfGetDB( DB_SLAVE );
                $res = $dbr->select( 'protected_titles', '*', 
-                       array ('pt_namespace' => $this->getNamespace(), 'pt_title' => $this->getDBKey()) );
+                       array ('pt_namespace' => $this->getNamespace(), 'pt_title' => $this->getDBkey()) );
 
                if ($row = $dbr->fetchRow( $res )) {
                        return $row;
@@ -1281,7 +1281,7 @@ class Title {
                        return true;
                }
 
-               list ($namespace, $title) = array( $this->getNamespace(), $this->getDBKey() );
+               list ($namespace, $title) = array( $this->getNamespace(), $this->getDBkey() );
 
                $dbw = wfGetDB( DB_MASTER );
 
@@ -1323,7 +1323,7 @@ class Title {
                $dbw = wfGetDB( DB_MASTER );
 
                $dbw->delete( 'protected_titles', 
-                       array ('pt_namespace' => $this->getNamespace(), 'pt_title' => $this->getDBKey()), __METHOD__ );
+                       array ('pt_namespace' => $this->getNamespace(), 'pt_title' => $this->getDBkey()), __METHOD__ );
        }
 
        /**
@@ -1419,7 +1419,7 @@ class Title {
                         * and check again
                         */
                        if( $this->getNamespace() == NS_SPECIAL ) {
-                               $name = $this->getDBKey();
+                               $name = $this->getDBkey();
                                list( $name, /* $subpage */) = SpecialPage::resolveAliasWithSubpage( $name );
                                if ( $name === false ) {
                                        # Invalid special page, but we show standard login required message
@@ -2766,7 +2766,7 @@ class Title {
                // Note: === is necessary for proper matching of number-like titles.
                return $this->getInterwiki() === $title->getInterwiki()
                        && $this->getNamespace() == $title->getNamespace()
-                       && $this->getDbkey() === $title->getDbkey();
+                       && $this->getDBkey() === $title->getDBkey();
        }
        
        /**