From e2a069fd89dcf784faa7bff19898810fb8744806 Mon Sep 17 00:00:00 2001 From: Brion Vibber Date: Mon, 27 Aug 2007 18:56:31 +0000 Subject: [PATCH] * (bug 11082) Fix check for fully-specced table names in Database::tableName strpos() was in wrong order since added in 2004 :D --- RELEASE-NOTES | 2 ++ includes/Database.php | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/RELEASE-NOTES b/RELEASE-NOTES index 802b57c1f6..cb2b838a23 100644 --- a/RELEASE-NOTES +++ b/RELEASE-NOTES @@ -419,6 +419,8 @@ it from source control: http://www.mediawiki.org/wiki/Download_from_SVN * Double encoding broke Special:Newpages for some languages * Adding a newline before the statistics footer, to prevent parsing problems * Preventing the TOC from appearing in Special:Statistics +* (bug 11082) Fix check for fully-specced table names in Database::tableName + == API changes since 1.10 == diff --git a/includes/Database.php b/includes/Database.php index 7e5266fc83..5387ed411a 100644 --- a/includes/Database.php +++ b/includes/Database.php @@ -1582,7 +1582,7 @@ class Database { global $wgSharedDB; # Skip quoted literals if ( $name{0} != '`' ) { - if ( $this->mTablePrefix !== '' && strpos( '.', $name ) === false ) { + if ( $this->mTablePrefix !== '' && strpos( $name, '.' ) === false ) { $name = "{$this->mTablePrefix}$name"; } if ( isset( $wgSharedDB ) && "{$this->mTablePrefix}user" == $name ) { -- 2.20.1