Index: trunk/phase3/includes/installer/DatabaseUpdater.php |
— | — | @@ -31,12 +31,6 @@ |
32 | 32 | protected $extensionUpdates = array(); |
33 | 33 | |
34 | 34 | /** |
35 | | - * List of extension-provided database updaters |
36 | | - * @var array |
37 | | - */ |
38 | | - protected $extensionUpdaters = array(); |
39 | | - |
40 | | - /** |
41 | 35 | * Used to hold schema files during installation process |
42 | 36 | * @var array |
43 | 37 | */ |
— | — | @@ -173,17 +167,6 @@ |
174 | 168 | } |
175 | 169 | |
176 | 170 | /** |
177 | | - * Add a updater class that will handle extensions DB install/update. |
178 | | - * This should be called by extensions while executing the |
179 | | - * LoadExtensionSchemaUpdates hook. |
180 | | - * |
181 | | - * @param $updater (string) classname (extends DatabaseUpdater). |
182 | | - */ |
183 | | - public function addExtensionUpdater( $updater ) { |
184 | | - $this->extensionUpdaters[] = $updater; |
185 | | - } |
186 | | - |
187 | | - /** |
188 | 171 | * Convenience wrapper for addExtensionUpdate() when adding a new table (which |
189 | 172 | * is the most common usage of updaters in an extension) |
190 | 173 | * @param $tableName String Name of table to create |
— | — | @@ -219,15 +202,6 @@ |
220 | 203 | return $this->extensionUpdates; |
221 | 204 | } |
222 | 205 | |
223 | | - /** |
224 | | - * Get the list of extension-defined updaters |
225 | | - * |
226 | | - * @return Array |
227 | | - */ |
228 | | - protected function getExtensionUpdaters() { |
229 | | - return $this->extensionUpdaters; |
230 | | - } |
231 | | - |
232 | 206 | public function getPostDatabaseUpdateMaintenance() { |
233 | 207 | return $this->postDatabaseUpdateMaintenance; |
234 | 208 | } |
— | — | @@ -247,10 +221,6 @@ |
248 | 222 | if ( isset( $what['extensions'] ) ) { |
249 | 223 | $this->runUpdates( $this->getOldGlobalUpdates(), false ); |
250 | 224 | $this->runUpdates( $this->getExtensionUpdates(), true ); |
251 | | - foreach ( $this->getExtensionUpdaters() as $updaterClass ) { |
252 | | - $eupdater = new $updaterClass( $this ); |
253 | | - $eupdater->doUpdates(); |
254 | | - } |
255 | 225 | } |
256 | 226 | |
257 | 227 | $this->setAppliedUpdates( $wgVersion, $this->updates ); |
Index: trunk/phase3/includes/installer/ExtensionUpdater.php |
— | — | @@ -1,16 +0,0 @@ |
2 | | -<?php |
3 | | - |
4 | | -class ExtensionUpdater extends DatabaseUpdater { |
5 | | - |
6 | | - // overload the constructor, so the init and hooks don't get called |
7 | | - // while still have all the patching code without duplicating |
8 | | - public function __construct( DatabaseBase &$db, $shared, Maintenance $maintenance = null ) { |
9 | | - $this->db = $db; |
10 | | - $this->shared = $shared; |
11 | | - $this->maintenance = $maintenance; |
12 | | - } |
13 | | - |
14 | | - public function doUpdates() { |
15 | | - $this->runUpdates( $this->getCoreUpdateList(), false ); |
16 | | - } |
17 | | -} |