r53779 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r53778‎ | r53779 | r53780 >
Date:12:45, 26 July 2009
Author:catrope
Status:deferred
Tags:
Comment:
Fix up r53775: use $wgExtNewTables in WhosOnline extension
Modified paths:
  • /trunk/extensions/WhosOnline/WhosOnline.php (modified) (history)

Diff [purge]

Index: trunk/extensions/WhosOnline/WhosOnline.php
@@ -62,12 +62,9 @@
6363 $wgHooks['LoadExtensionSchemaUpdates'][] = 'wfWhosOnlineCheckSchema';
6464
6565 function wfWhosOnlineCheckSchema() {
66 - // Get a connection
67 - $db = wfGetDB( DB_MASTER );
68 - // Create table if it doesn't exist
69 - if ( !$db->tableExists( 'online' ) ) {
70 - $db->sourceFile( dirname( __FILE__ ) . '/whosonline.sql' );
71 - }
 66+ global $wgExtNewTables;
 67+ $wgExtNewTables[] = array( 'online',
 68+ dirname( __FILE__ ) . '/whosonline.sql' );
7269 // Continue
7370 return true;
7471 }

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r53775Allow to automatically create the database table `online`.purodha08:53, 26 July 2009

Status & tagging log