Index: trunk/phase3/maintenance/deleteArchivedFiles.php |
— | — | @@ -30,6 +30,7 @@ |
31 | 31 | parent::__construct(); |
32 | 32 | $this->mDescription = "Deletes all archived images."; |
33 | 33 | $this->addOption( 'delete', 'Perform the deletion' ); |
| 34 | + $this->addOption( 'force', 'Force deletion of rows from filearchive' ); |
34 | 35 | } |
35 | 36 | |
36 | 37 | public function execute() { |
— | — | @@ -37,10 +38,7 @@ |
38 | 39 | $this->output( "Use --delete to actually confirm this script\n" ); |
39 | 40 | return; |
40 | 41 | } |
41 | | - $force = false; |
42 | | - if( $this->hasOption('force') ) { |
43 | | - $force = true; |
44 | | - } |
| 42 | + $force = $this->hasOption( 'force '); |
45 | 43 | # Data should come off the master, wrapped in a transaction |
46 | 44 | $dbw = wfGetDB( DB_MASTER ); |
47 | 45 | $dbw->begin(); |