r99575 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r99574‎ | r99575 | r99576 >
Date:21:28, 11 October 2011
Author:reedy
Status:ok
Tags:
Comment:
MFT r99574
Modified paths:
  • /branches/wmf/1.18wmf1/maintenance/mergeMessageFileList.php (modified) (history)

Diff [purge]

Index: branches/wmf/1.18wmf1/maintenance/mergeMessageFileList.php
@@ -32,7 +32,7 @@
3333
3434 function __construct() {
3535 parent::__construct();
36 - $this->addOption( 'list-file', 'A file containing a list of extension setup files, one per line.', false, true );
 36+ $this->addOption( 'list-file', 'A file containing a list of extension setup files, one per line.', true, true );
3737 $this->addOption( 'output', 'Send output to this file (omit for stdout)', false, true );
3838 $this->mDescription = 'Merge $wgExtensionMessagesFiles from various extensions to produce a ' .
3939 'single array containing all message files.';
@@ -40,10 +40,6 @@
4141
4242 public function execute() {
4343 global $mmfl;
44 - if ( !$this->hasOption( 'list-file' ) ) {
45 - $this->error( 'The --list-file option must be specified.' );
46 - return;
47 - }
4844
4945 $lines = file( $this->getOption( 'list-file' ) );
5046 if ( $lines === false ) {

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r99574Don't reinvent the wheel to do parameter existence checking...reedy21:28, 11 October 2011

Status & tagging log