http://www.mediawiki.org/wiki/Special:Code/MediaWiki/72178

Revision: 72178
Author:   siebrand
Date:     2010-09-01 23:21:24 +0000 (Wed, 01 Sep 2010)

Log Message:
-----------
Update documentation and fix an 'undefined index groups' when run without any 
arguments.

Modified Paths:
--------------
    trunk/extensions/Translate/scripts/groupStatistics.php

Modified: trunk/extensions/Translate/scripts/groupStatistics.php
===================================================================
--- trunk/extensions/Translate/scripts/groupStatistics.php      2010-09-01 
23:18:21 UTC (rev 72177)
+++ trunk/extensions/Translate/scripts/groupStatistics.php      2010-09-01 
23:21:24 UTC (rev 72178)
@@ -86,7 +86,9 @@
  * group in the sum of the values for all the groups in the array.
  *
  * Definitions in this variable can be used to report weighted meta 
localisation
- * scores.
+ * scores for the 50 most spoken languages.
+ *
+ * @todo Allow weighted reporting for all available languges.
  */
 $localisedWeights = array(
        'wikimedia' => array(
@@ -177,7 +179,9 @@
 require( dirname( __FILE__ ) . '/cli.inc' );
 
 /**
- * @todo Needs documentation.
+ * Provides heading, summaryheading and free text addition for stats output in
+ * wiki format.
+ *
  * @ingroup Stats
  */
 class TranslateStatsOutput extends wikiStatsOutput {
@@ -201,6 +205,8 @@
 // Show help and exit if '--most' does not have a valid value and no groups set
 if ( isset( $options['most'] ) && !isset( $localisedWeights[$options['most']] 
) && !isset( $options['groups'] ) ) {
        showUsage();
+} elseif ( !isset( $options['most'] ) && !isset( $options['groups'] ) ) {
+       showUsage();
 }
 
 if ( !isset( $options['output'] ) ) {



_______________________________________________
MediaWiki-CVS mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs

Reply via email to