summaryrefslogtreecommitdiff
path: root/maintenance/refreshImageMetadata.php
diff options
context:
space:
mode:
Diffstat (limited to 'maintenance/refreshImageMetadata.php')
-rw-r--r--maintenance/refreshImageMetadata.php16
1 files changed, 8 insertions, 8 deletions
diff --git a/maintenance/refreshImageMetadata.php b/maintenance/refreshImageMetadata.php
index 12da7a8b..7fe5c4c1 100644
--- a/maintenance/refreshImageMetadata.php
+++ b/maintenance/refreshImageMetadata.php
@@ -27,7 +27,7 @@
* @ingroup Maintenance
*/
-require_once( __DIR__ . '/Maintenance.php' );
+require_once __DIR__ . '/Maintenance.php';
/**
* Maintenance script to refresh image metadata fields.
@@ -53,7 +53,7 @@ class RefreshImageMetadata extends Maintenance {
$this->addOption( 'start', 'Name of file to start with', false, true );
$this->addOption( 'end', 'Name of file to end with', false, true );
- $this->addOption( 'mime', '(Inefficient!) Only refresh files with this mime type. Can accept wild-card image/*' , false, true );
+ $this->addOption( 'mime', '(Inefficient!) Only refresh files with this mime type. Can accept wild-card image/*', false, true );
$this->addOption( 'metadata-contains', '(Inefficient!) Only refresh files where the img_metadata field contains this string. Can be used if its known a specific property was being extracted incorrectly.', false, true );
}
@@ -99,7 +99,7 @@ class RefreshImageMetadata extends Maintenance {
if ( $res->numRows() > 0 ) {
$row1 = $res->current();
- $this->output( "Processing next {$this->mBatchSize} rows starting with {$row1->img_name}.\n");
+ $this->output( "Processing next {$this->mBatchSize} rows starting with {$row1->img_name}.\n" );
$res->rewind();
} else {
$this->error( "No images to process.", 4 );
@@ -123,7 +123,7 @@ class RefreshImageMetadata extends Maintenance {
$this->output( "Warning: File:{$row->img_name} used to have " .
"$oldLength bytes of metadata but now has $newLength bytes.\n" );
} elseif ( $verbose ) {
- $this->output("Refreshed File:{$row->img_name}.\n" );
+ $this->output( "Refreshed File:{$row->img_name}.\n" );
}
} else {
$leftAlone++;
@@ -138,7 +138,7 @@ class RefreshImageMetadata extends Maintenance {
}
if ( $verbose ) {
- $this->output("Forcibly refreshed File:{$row->img_name}.\n" );
+ $this->output( "Forcibly refreshed File:{$row->img_name}.\n" );
}
}
else {
@@ -151,7 +151,7 @@ class RefreshImageMetadata extends Maintenance {
}
$conds2 = array( 'img_name > ' . $dbw->addQuotes( $row->img_name ) );
wfWaitForSlaves();
- } while( $res->numRows() === $this->mBatchSize );
+ } while ( $res->numRows() === $this->mBatchSize );
$total = $upgraded + $leftAlone;
if ( $force ) {
@@ -173,7 +173,7 @@ class RefreshImageMetadata extends Maintenance {
$like = $this->getOption( 'metadata-contains', false );
if ( $end !== false ) {
- $conds[] = 'img_name <= ' . $dbw->addQuotes( $end ) ;
+ $conds[] = 'img_name <= ' . $dbw->addQuotes( $end );
}
if ( $mime !== false ) {
list( $major, $minor ) = File::splitMime( $mime );
@@ -209,4 +209,4 @@ class RefreshImageMetadata extends Maintenance {
$maintClass = 'RefreshImageMetadata';
-require_once( RUN_MAINTENANCE_IF_MAIN );
+require_once RUN_MAINTENANCE_IF_MAIN;