Index: trunk/phase3/languages/Language.php |
— | — | @@ -402,21 +402,13 @@ |
403 | 403 | } |
404 | 404 | |
405 | 405 | /** |
406 | | - * Ugly hack to get a message maybe from the MediaWiki namespace, if this |
407 | | - * language object is the content or user language. |
| 406 | + * Get a message from the MediaWiki namespace. |
| 407 | + * |
| 408 | + * @param $msg String: message name |
| 409 | + * @return string |
408 | 410 | */ |
409 | 411 | function getMessageFromDB( $msg ) { |
410 | | - global $wgContLang, $wgLang; |
411 | | - if ( $wgContLang->getCode() == $this->getCode() ) { |
412 | | - # Content language |
413 | | - return wfMsgForContent( $msg ); |
414 | | - } elseif ( $wgLang->getCode() == $this->getCode() ) { |
415 | | - # User language |
416 | | - return wfMsg( $msg ); |
417 | | - } else { |
418 | | - # Neither, get from localisation |
419 | | - return $this->getMessage( $msg ); |
420 | | - } |
| 412 | + return wfMsgExt( $msg, array( 'parsemag', 'language' => $this ) ); |
421 | 413 | } |
422 | 414 | |
423 | 415 | function getLanguageName( $code ) { |