From c18123cb90abd9a34c41c5e4f9514ca4d3688ddb Mon Sep 17 00:00:00 2001 From: Brion Vibber Date: Mon, 6 Jun 2011 18:35:28 +0000 Subject: [PATCH] Revert r89263, r89297, r89347: unclear whether this is needed; DatabaseUpdater actions list is already extensible and it might just need some rearrangement? --- includes/installer/DatabaseUpdater.php | 30 ------------------------- includes/installer/ExtensionUpdater.php | 16 ------------- 2 files changed, 46 deletions(-) diff --git a/includes/installer/DatabaseUpdater.php b/includes/installer/DatabaseUpdater.php index c09a229421..fddffd35b6 100644 --- a/includes/installer/DatabaseUpdater.php +++ b/includes/installer/DatabaseUpdater.php @@ -30,12 +30,6 @@ abstract class DatabaseUpdater { */ protected $extensionUpdates = array(); - /** - * List of extension-provided database updaters - * @var array - */ - protected $extensionUpdaters = array(); - /** * Used to hold schema files during installation process * @var array @@ -172,17 +166,6 @@ abstract class DatabaseUpdater { $this->extensionUpdates[] = $update; } - /** - * Add a updater class that will handle extensions DB install/update. - * This should be called by extensions while executing the - * LoadExtensionSchemaUpdates hook. - * - * @param $updater (string) classname (extends DatabaseUpdater). - */ - public function addExtensionUpdater( $updater ) { - $this->extensionUpdaters[] = $updater; - } - /** * Convenience wrapper for addExtensionUpdate() when adding a new table (which * is the most common usage of updaters in an extension) @@ -219,15 +202,6 @@ abstract class DatabaseUpdater { return $this->extensionUpdates; } - /** - * Get the list of extension-defined updaters - * - * @return Array - */ - protected function getExtensionUpdaters() { - return $this->extensionUpdaters; - } - public function getPostDatabaseUpdateMaintenance() { return $this->postDatabaseUpdateMaintenance; } @@ -247,10 +221,6 @@ abstract class DatabaseUpdater { if ( isset( $what['extensions'] ) ) { $this->runUpdates( $this->getOldGlobalUpdates(), false ); $this->runUpdates( $this->getExtensionUpdates(), true ); - foreach ( $this->getExtensionUpdaters() as $updaterClass ) { - $eupdater = new $updaterClass( $this ); - $eupdater->doUpdates(); - } } $this->setAppliedUpdates( $wgVersion, $this->updates ); diff --git a/includes/installer/ExtensionUpdater.php b/includes/installer/ExtensionUpdater.php index d827af022d..e69de29bb2 100644 --- a/includes/installer/ExtensionUpdater.php +++ b/includes/installer/ExtensionUpdater.php @@ -1,16 +0,0 @@ -db = $db; - $this->shared = $shared; - $this->maintenance = $maintenance; - } - - public function doUpdates() { - $this->runUpdates( $this->getCoreUpdateList(), false ); - } -} -- 2.20.1