r108178 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r108177‎ | r108178 | r108179 >
Date:21:40, 5 January 2012
Author:yaron
Status:ok
Tags:
Comment:
Removed DTUtils::loadMessages() method - no longer needed, since versions of MediaWiki less than 1.16 are no longer being supported
Modified paths:
  • /trunk/extensions/DataTransfer/includes/DT_Utils.php (modified) (history)
  • /trunk/extensions/DataTransfer/specials/DT_ImportCSV.php (modified) (history)
  • /trunk/extensions/DataTransfer/specials/DT_ImportXML.php (modified) (history)
  • /trunk/extensions/DataTransfer/specials/DT_ViewXML.php (modified) (history)

Diff [purge]

Index: trunk/extensions/DataTransfer/specials/DT_ImportCSV.php
@@ -55,9 +55,7 @@
5656 * Constructor
5757 */
5858 public function DTImportCSV() {
59 - global $wgLanguageCode;
6059 parent::__construct( 'ImportCSV' );
61 - DTUtils::loadMessages();
6260 }
6361
6462 function execute( $query ) {
Index: trunk/extensions/DataTransfer/specials/DT_ImportXML.php
@@ -13,9 +13,7 @@
1414 * Constructor
1515 */
1616 public function DTImportXML() {
17 - global $wgLanguageCode;
1817 parent::__construct( 'ImportXML' );
19 - DTUtils::loadMessages();
2018 }
2119
2220 function execute( $query ) {
Index: trunk/extensions/DataTransfer/specials/DT_ViewXML.php
@@ -13,9 +13,7 @@
1414 * Constructor
1515 */
1616 public function DTViewXML() {
17 - global $wgLanguageCode;
1817 parent::__construct( 'ViewXML' );
19 - DTUtils::loadMessages();
2018 }
2119
2220 function execute( $query ) {
Index: trunk/extensions/DataTransfer/includes/DT_Utils.php
@@ -7,16 +7,6 @@
88 */
99 class DTUtils {
1010
11 - /**
12 - * Loads messages only for MediaWiki versions that need it (< 1.16)
13 - */
14 - public static function loadMessages() {
15 - global $wgVersion;
16 - if ( version_compare( $wgVersion, '1.16', '<' ) ) {
17 - wfLoadExtensionMessages( 'DataTransfer' );
18 - }
19 - }
20 -
2111 static function printImportingMessage() {
2212 return "\t" . Xml::element( 'p', null, wfMsg( 'dt_import_importing' ) ) . "\n";
2313 }

Status & tagging log