From d6456e1e41d24677249fde0ccf8f63d9ae9e2140 Mon Sep 17 00:00:00 2001 From: Greg Sabino Mullane Date: Wed, 21 Mar 2007 18:19:35 +0000 Subject: [PATCH] Remove variables when we can simply override accessors instead. --- includes/Database.php | 9 +++------ includes/DatabaseOracle.php | 14 +++++++++----- includes/DatabasePostgres.php | 14 +++++++++----- 3 files changed, 21 insertions(+), 16 deletions(-) diff --git a/includes/Database.php b/includes/Database.php index 589cc148a6..4bfc84b14d 100644 --- a/includes/Database.php +++ b/includes/Database.php @@ -295,9 +295,6 @@ class Database { protected $mTrxLevel = 0; protected $mErrorCount = 0; protected $mLBInfo = array(); - protected $mCascadingDeletes = false; - protected $mCleanupTriggers = false; - protected $mStrictIPs = false; #------------------------------------------------------------------------------ # Accessors @@ -392,14 +389,14 @@ class Database { * Returns true if this database supports (and uses) cascading deletes */ function cascadingDeletes() { - return $this->mCascadingDeletes; + return false; } /** * Returns true if this database supports (and uses) triggers (e.g. on the page table) */ function cleanupTriggers() { - return $this->mCleanupTriggers; + return false; } /** @@ -407,7 +404,7 @@ class Database { * Specifically, it uses a NULL value instead of an empty string. */ function strictIPs() { - return $this->mStrictIPs; + return false; } /** diff --git a/includes/DatabaseOracle.php b/includes/DatabaseOracle.php index 513cb4e7ba..7560039353 100644 --- a/includes/DatabaseOracle.php +++ b/includes/DatabaseOracle.php @@ -104,22 +104,26 @@ class DatabaseOracle extends Database { } $this->mOut =& $wgOut; $this->mFailFunction = $failFunction; - $this->mCascadingDeletes = true; - $this->mCleanupTriggers = true; - $this->mStrictIPs = true; $this->mFlags = $flags; $this->open( $server, $user, $password, $dbName); } + function cascadingDeletes() { + return true; + } + function cleanupTriggers() { + return true; + } + function strictIPs() { + return true; + } function realTimestamps() { return true; } - function implicitGroupby() { return false; } - function searchableIPs() { return true; } diff --git a/includes/DatabasePostgres.php b/includes/DatabasePostgres.php index 36a0b64fff..93051b616a 100644 --- a/includes/DatabasePostgres.php +++ b/includes/DatabasePostgres.php @@ -74,22 +74,26 @@ class DatabasePostgres extends Database { } $this->mOut =& $wgOut; $this->mFailFunction = $failFunction; - $this->mCascadingDeletes = true; - $this->mCleanupTriggers = true; - $this->mStrictIPs = true; $this->mFlags = $flags; $this->open( $server, $user, $password, $dbName); } + function cascadingDeletes() { + return true; + } + function cleanupTriggers() { + return true; + } + function strictIPs() { + return true; + } function realTimestamps() { return true; } - function implicitGroupby() { return false; } - function searchableIPs() { return true; } -- 2.20.1