r59625 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r59624‎ | r59625 | r59626 >
Date:13:59, 1 December 2009
Author:purodha
Status:deferred
Tags:
Comment:
PLURAL support for message validator_error_parameters, on the number of syntax errors.
Typo correctd in comment.
Modified paths:
  • /trunk/extensions/Validator/Validator_Manager.php (modified) (history)

Diff [purge]

Index: trunk/extensions/Validator/Validator_Manager.php
@@ -59,8 +59,9 @@
6060 global $wgLang;
6161 global $egValidatorErrorLevel;
6262
63 - if ( $egValidatorErrorLevel >= Validator_ERRORS_SHOW && count( $this->errors ) > 0 ) {
64 - $errorList = '<b>' . wfMsg( 'validator_error_parameters' ) . ':</b><br /><i>';
 63+ $error_count = count( $this->errors ) ;
 64+ if ( $egValidatorErrorLevel >= Validator_ERRORS_SHOW && $error_count > 0 ) {
 65+ $errorList = '<b>' . wfMsgExt( 'validator_error_parameters', 'parsemag', $error_count ) . ':</b><br /><i>';
6566
6667 $errors = array();
6768
@@ -74,7 +75,7 @@
7576 case 'missing' :
7677 $errors[] = wfMsgExt( 'validator_error_required_missing', array( 'parsemag' ), $error['name'] );
7778 break;
78 - // Spesific validation faliures
 79+ // Specific validation faliures
7980 case 'not_empty' :
8081 $errors[] = wfMsgExt( 'validator_error_empty_argument', array( 'parsemag' ), $error['name'] );
8182 break;

Follow-up revisions

RevisionCommit summaryAuthorDate
r59784Followup to r59625: reverting r59626 in favour of adapting the english message....purodha12:13, 7 December 2009

Status & tagging log