Index: trunk/extensions/DonationInterface/gateway_common/DataValidator.php |
— | — | @@ -238,6 +238,7 @@ |
239 | 239 | * @return boolean - true if message exists, otherwise false. |
240 | 240 | */ |
241 | 241 | public static function wmfMessageExists( $msg_key, $language ){ |
| 242 | + $language = strtolower( $language ); |
242 | 243 | if ( wfMessage( $msg_key )->inLanguage( $language )->exists() ){ |
243 | 244 | # if we are looking for English, we already know the answer |
244 | 245 | if ( $language == 'en' ){ |
— | — | @@ -264,9 +265,7 @@ |
265 | 266 | * @return String the text of the first existant message |
266 | 267 | * @throws MWException if no message keys are specified |
267 | 268 | */ |
268 | | - public static function wfLangSpecificFallback( $language /*...*/ ){ |
269 | | - $msg_keys = func_get_args(); |
270 | | - array_shift( $msg_keys ); |
| 269 | + public static function wfLangSpecificFallback( $language='en', $msg_keys=array() ){ |
271 | 270 | |
272 | 271 | if ( count( $msg_keys ) < 1 ){ |
273 | 272 | throw new MWException( __FUNCTION__ . " BAD PROGRAMMER. No message keys given." ); |