summaryrefslogtreecommitdiff
path: root/maintenance/rebuildImages.php
diff options
context:
space:
mode:
Diffstat (limited to 'maintenance/rebuildImages.php')
-rw-r--r--maintenance/rebuildImages.php8
1 files changed, 4 insertions, 4 deletions
diff --git a/maintenance/rebuildImages.php b/maintenance/rebuildImages.php
index 46b5d0ed..0d3bdb3f 100644
--- a/maintenance/rebuildImages.php
+++ b/maintenance/rebuildImages.php
@@ -32,7 +32,7 @@
$options = array( 'missing', 'dry-run' );
-require_once( 'commandLine.inc' );
+require_once( dirname(__FILE__) . '/commandLine.inc' );
require_once( 'FiveUpgrade.inc' );
class ImageBuilder extends FiveUpgrade {
@@ -104,7 +104,7 @@ class ImageBuilder extends FiveUpgrade {
$result = $this->dbr->query( $sql, $fname );
while( $row = $this->dbr->fetchObject( $result ) ) {
- $update = call_user_func( $callback, $row );
+ $update = call_user_func( $callback, $row, null );
if( $update ) {
$this->progress( 1 );
} else {
@@ -120,7 +120,7 @@ class ImageBuilder extends FiveUpgrade {
$this->buildTable( 'image', 'img_name', $callback );
}
- function imageCallback( $row ) {
+ function imageCallback( $row, $copy ) {
// Create a File object from the row
// This will also upgrade it
$file = $this->getRepo()->newFileFromRow( $row );
@@ -132,7 +132,7 @@ class ImageBuilder extends FiveUpgrade {
array( &$this, 'oldimageCallback' ) );
}
- function oldimageCallback( $row ) {
+ function oldimageCallback( $row, $copy ) {
// Create a File object from the row
// This will also upgrade it
if ( $row->oi_archive_name == '' ) {