}
$db = $this->getDB( DB_MASTER );
- $ancientTables = array(
+ $ancientTables = [
'blobs', // 1.4
'brokenlinks', // 1.4
'cur', // 1.4
'trackback', // 1.19
'user_rights', // 1.5
'validate', // 1.6
- );
+ ];
foreach ( $ancientTables as $table ) {
if ( $db->tableExists( $table, __METHOD__ ) ) {
$this->output( "Cleaning up text table\n" );
- $oldIndexes = array(
+ $oldIndexes = [
'old_namespace',
'old_timestamp',
'name_title_timestamp',
'user_timestamp',
'usertext_timestamp',
- );
+ ];
foreach ( $oldIndexes as $index ) {
if ( $db->indexExists( 'text', $index, __METHOD__ ) ) {
$this->output( "Dropping index $index from the text table..." );
}
}
- $oldFields = array(
+ $oldFields = [
'old_namespace',
'old_title',
'old_comment',
'old_timestamp',
'old_minor_edit',
'inverse_timestamp',
- );
+ ];
foreach ( $oldFields as $field ) {
if ( $db->fieldExists( 'text', $field, __METHOD__ ) ) {
$this->output( "Dropping the $field field from the text table..." );
}
}
-$maintClass = "CleanupAncientTables";
+$maintClass = CleanupAncientTables::class;
require_once RUN_MAINTENANCE_IF_MAIN;