r69549 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r69548‎ | r69549 | r69550 >
Date:14:27, 19 July 2010
Author:ashley
Status:ok
Tags:
Comment:
SocialProfile: reapplying ^demon's r66934 - wfLoadExtensionMessages() is a no-op in 1.16 and trunk, and we require at least 1.16
Modified paths:
  • /trunk/extensions/SocialProfile/SystemGifts/SpecialSystemGiftManager.php (modified) (history)
  • /trunk/extensions/SocialProfile/SystemGifts/SpecialSystemGiftManagerLogo.php (modified) (history)
  • /trunk/extensions/SocialProfile/SystemGifts/SpecialViewSystemGift.php (modified) (history)
  • /trunk/extensions/SocialProfile/SystemGifts/SpecialViewSystemGifts.php (modified) (history)
  • /trunk/extensions/SocialProfile/SystemGifts/UserSystemGiftsClass.php (modified) (history)
  • /trunk/extensions/SocialProfile/UserActivity/SiteActivityHook.php (modified) (history)
  • /trunk/extensions/SocialProfile/UserActivity/UserActivity.body.php (modified) (history)
  • /trunk/extensions/SocialProfile/UserBoard/SpecialSendBoardBlast.php (modified) (history)
  • /trunk/extensions/SocialProfile/UserBoard/SpecialUserBoard.php (modified) (history)
  • /trunk/extensions/SocialProfile/UserBoard/UserBoardClass.php (modified) (history)
  • /trunk/extensions/SocialProfile/UserGifts/SpecialGiftManager.php (modified) (history)
  • /trunk/extensions/SocialProfile/UserGifts/SpecialGiftManagerLogo.php (modified) (history)
  • /trunk/extensions/SocialProfile/UserGifts/SpecialGiveGift.php (modified) (history)
  • /trunk/extensions/SocialProfile/UserGifts/SpecialRemoveGift.php (modified) (history)
  • /trunk/extensions/SocialProfile/UserGifts/SpecialRemoveMasterGift.php (modified) (history)
  • /trunk/extensions/SocialProfile/UserGifts/SpecialViewGift.php (modified) (history)
  • /trunk/extensions/SocialProfile/UserGifts/SpecialViewGifts.php (modified) (history)
  • /trunk/extensions/SocialProfile/UserGifts/UserGiftsClass.php (modified) (history)
  • /trunk/extensions/SocialProfile/UserProfile/SpecialPopulateExistingUsersProfiles.php (modified) (history)
  • /trunk/extensions/SocialProfile/UserProfile/SpecialRemoveAvatar.php (modified) (history)
  • /trunk/extensions/SocialProfile/UserProfile/SpecialUpdateProfile.php (modified) (history)
  • /trunk/extensions/SocialProfile/UserProfile/SpecialUploadAvatar.php (modified) (history)
  • /trunk/extensions/SocialProfile/UserProfile/UserProfilePage.php (modified) (history)
  • /trunk/extensions/SocialProfile/UserRelationship/Relationship_AjaxFunctions.php (modified) (history)
  • /trunk/extensions/SocialProfile/UserRelationship/SpecialAddRelationship.php (modified) (history)
  • /trunk/extensions/SocialProfile/UserRelationship/SpecialRemoveRelationship.php (modified) (history)
  • /trunk/extensions/SocialProfile/UserRelationship/SpecialViewRelationshipRequests.php (modified) (history)
  • /trunk/extensions/SocialProfile/UserRelationship/SpecialViewRelationships.php (modified) (history)
  • /trunk/extensions/SocialProfile/UserRelationship/UserRelationshipClass.php (modified) (history)
  • /trunk/extensions/SocialProfile/UserStats/TopFansByStat.php (modified) (history)
  • /trunk/extensions/SocialProfile/UserStats/TopFansRecent.php (modified) (history)
  • /trunk/extensions/SocialProfile/UserStats/TopUsers.php (modified) (history)
  • /trunk/extensions/SocialProfile/UserStats/UserStatsClass.php (modified) (history)
  • /trunk/extensions/SocialProfile/UserSystemMessages/UserSystemMessagesClass.php (modified) (history)
  • /trunk/extensions/SocialProfile/UserWelcome/UserWelcome.php (modified) (history)

Diff [purge]

Index: trunk/extensions/SocialProfile/UserWelcome/UserWelcome.php
@@ -49,7 +49,6 @@
5050
5151 function getWelcome() {
5252 global $wgUser, $wgOut, $wgScriptPath, $wgUploadPath;
53 - wfLoadExtensionMessages( 'UserWelcome' );
5453
5554 // Add CSS
5655 $wgOut->addExtensionStyle( $wgScriptPath . '/extensions/SocialProfile/UserWelcome/UserWelcome.css' );
@@ -107,8 +106,6 @@
108107 }
109108
110109 function getRequests() {
111 - wfLoadExtensionMessages( 'UserWelcome' );
112 -
113110 // Get requests
114111 $requests = getNewMessagesLink() . getRelationshipRequestLink() .
115112 getNewGiftLink() . getNewSystemGiftLink();
@@ -129,7 +126,6 @@
130127
131128 function getRelationshipRequestLink() {
132129 global $wgUser, $wgScriptPath;
133 - wfLoadExtensionMessages( 'UserWelcome' );
134130 $friend_request_count = UserRelationship::getOpenRequestCount( $wgUser->getID(), 1 );
135131 $foe_request_count = UserRelationship::getOpenRequestCount( $wgUser->getID(), 2 );
136132 $relationship_request_link = SpecialPage::getTitleFor( 'ViewRelationshipRequests' );
@@ -157,7 +153,6 @@
158154
159155 function getNewGiftLink() {
160156 global $wgUser, $wgScriptPath;
161 - wfLoadExtensionMessages( 'UserWelcome' );
162157 $gift_count = UserGifts::getNewGiftCount( $wgUser->getID() );
163158 $gifts_title = SpecialPage::getTitleFor( 'ViewGifts' );
164159 $output = '';
@@ -174,7 +169,6 @@
175170
176171 function getNewSystemGiftLink() {
177172 global $wgUser, $wgScriptPath;
178 - wfLoadExtensionMessages( 'UserWelcome' );
179173 $gift_count = UserSystemGifts::getNewSystemGiftCount( $wgUser->getID() );
180174 $gifts_title = SpecialPage::getTitleFor( 'ViewSystemGifts' );
181175 $output = '';
@@ -193,7 +187,6 @@
194188
195189 function getNewMessagesLink() {
196190 global $wgUser, $wgScriptPath;
197 - wfLoadExtensionMessages( 'UserWelcome' );
198191 $new_messages = UserBoard::getNewMessageCount( $wgUser->getID() );
199192 $output = '';
200193 if ( $new_messages ) {
Index: trunk/extensions/SocialProfile/UserActivity/SiteActivityHook.php
@@ -28,8 +28,6 @@
2929 // so that <siteactivity limit=5 /> will return 5 items instead of 4...
3030 $fixedLimit = $limit + 1;
3131
32 - wfLoadExtensionMessages( 'UserActivity' );
33 -
3432 $key = wfMemcKey( 'site_activity', 'all', $fixedLimit );
3533 $data = $wgMemc->get( $key );
3634 if ( !$data ) {
Index: trunk/extensions/SocialProfile/UserActivity/UserActivity.body.php
@@ -16,8 +16,6 @@
1717 public function execute( $par ) {
1818 global $wgUser, $wgOut, $wgRequest, $wgScriptPath;
1919
20 - wfLoadExtensionMessages( 'UserActivity' );
21 -
2220 $wgOut->addExtensionStyle( $wgScriptPath . '/extensions/SocialProfile/UserActivity/UserActivity.css' );
2321
2422 $wgOut->setPageTitle( wfMsg( 'useractivity-title' ) );
Index: trunk/extensions/SocialProfile/UserGifts/SpecialRemoveMasterGift.php
@@ -49,7 +49,6 @@
5050 */
5151 public function execute( $par ) {
5252 global $wgUser, $wgOut, $wgRequest, $wgUserGiftsScripts;
53 - wfLoadExtensionMessages( 'UserGifts' );
5453
5554 // Add CSS
5655 $wgOut->addExtensionStyle( $wgUserGiftsScripts . '/UserGifts.css' );
Index: trunk/extensions/SocialProfile/UserGifts/SpecialGiftManager.php
@@ -16,7 +16,6 @@
1717 */
1818 public function execute( $par ) {
1919 global $wgUser, $wgOut, $wgRequest, $wgScriptPath, $wgUserGiftsScripts;
20 - wfLoadExtensionMessages( 'UserGifts' );
2120
2221 $wgOut->setPageTitle( wfMsg( 'giftmanager' ) );
2322
@@ -116,7 +115,6 @@
117116
118117 function displayGiftList() {
119118 global $wgScriptPath;
120 - wfLoadExtensionMessages( 'UserGifts' );
121119 $output = ''; // Prevent E_NOTICE
122120 $page = 0;
123121 $per_page = 10;
@@ -134,7 +132,6 @@
135133
136134 function displayForm( $gift_id ) {
137135 global $wgUser, $wgOut, $wgScriptPath;
138 - wfLoadExtensionMessages( 'UserGifts' );
139136
140137 if ( !$gift_id && !$this->canUserCreateGift() ) {
141138 return $this->displayGiftList();
Index: trunk/extensions/SocialProfile/UserGifts/SpecialGiveGift.php
@@ -16,7 +16,6 @@
1717 */
1818 public function execute( $par ) {
1919 global $wgUser, $wgOut, $wgRequest, $wgMemc, $wgUploadPath, $wgUserGiftsScripts;
20 - wfLoadExtensionMessages( 'UserGifts' );
2120
2221 $output = ''; // Prevent E_NOTICE
2322
Index: trunk/extensions/SocialProfile/UserGifts/SpecialViewGift.php
@@ -16,7 +16,6 @@
1717 */
1818 public function execute( $par ) {
1919 global $wgUser, $wgOut, $wgRequest, $wgUploadPath, $wgUserGiftsScripts;
20 - wfLoadExtensionMessages( 'UserGifts' );
2120
2221 $wgOut->addExtensionStyle( $wgUserGiftsScripts . '/UserGifts.css' );
2322
Index: trunk/extensions/SocialProfile/UserGifts/SpecialGiftManagerLogo.php
@@ -417,7 +417,6 @@
418418 */
419419 function showSuccess( $status ) {
420420 global $wgOut, $wgUploadPath, $wgScriptPath, $wgLang;
421 - wfLoadExtensionMessages( 'UserGifts' );
422421 $ext = 'jpg';
423422
424423 $output = '<h2>' . wfMsg( 'g-uploadsuccess' ) . '</h2>';
@@ -457,7 +456,6 @@
458457 */
459458 function uploadError( $error ) {
460459 global $wgOut;
461 - wfLoadExtensionMessages( 'UserGifts' );
462460 $sub = wfMsg( 'uploadwarning' );
463461 $wgOut->addHTML( "<h2>{$sub}</h2>\n" );
464462 $wgOut->addHTML( "<h4 class='error'>{$error}</h4>\n" );
@@ -533,7 +531,6 @@
534532 */
535533 function mainUploadForm( $msg = '' ) {
536534 global $wgOut, $wgUser, $wgUseCopyrightUpload;
537 - wfLoadExtensionMessages( 'UserGifts' );
538535
539536 if ( !$this->canUserManage() ) {
540537 $wgOut->errorpage( 'error', 'badaccess' );
Index: trunk/extensions/SocialProfile/UserGifts/SpecialRemoveGift.php
@@ -16,7 +16,6 @@
1717 */
1818 public function execute( $par ) {
1919 global $wgUser, $wgOut, $wgRequest, $wgMemc, $wgUploadPath, $wgUserGiftsScripts;
20 - wfLoadExtensionMessages( 'UserGifts' );
2120
2221 $wgOut->addExtensionStyle( $wgUserGiftsScripts . '/UserGifts.css' );
2322
Index: trunk/extensions/SocialProfile/UserGifts/SpecialViewGifts.php
@@ -16,7 +16,6 @@
1717 */
1818 public function execute( $par ) {
1919 global $wgUser, $wgOut, $wgRequest, $wgMemc, $wgUploadPath, $wgUserGiftsScripts;
20 - wfLoadExtensionMessages( 'UserGifts' );
2120
2221 $wgOut->addExtensionStyle( $wgUserGiftsScripts . '/UserGifts.css' );
2322
Index: trunk/extensions/SocialProfile/UserGifts/UserGiftsClass.php
@@ -68,8 +68,6 @@
6969 }
7070
7171 public function sendGiftNotificationEmail( $user_id_to, $user_from, $gift_id, $type ) {
72 - wfLoadExtensionMessages( 'UserGifts' );
73 -
7472 $gift = Gifts::getGift( $gift_id );
7573 $user = User::newFromId( $user_id_to );
7674 $user->loadFromDatabase();
Index: trunk/extensions/SocialProfile/UserSystemMessages/UserSystemMessagesClass.php
@@ -98,7 +98,6 @@
9999 * @param $level Mixed: name of the level that the user advanced to
100100 */
101101 public function sendAdvancementNotificationEmail( $user_id_to, $level ) {
102 - wfLoadExtensionMessages( 'SocialProfileUserStats' );
103102 $user = User::newFromId( $user_id_to );
104103 $user->loadFromDatabase();
105104 if ( $user->isEmailConfirmed() && $user->getIntOption( 'notifyhonorifics', 1 ) ) {
Index: trunk/extensions/SocialProfile/UserStats/TopFansRecent.php
@@ -18,9 +18,6 @@
1919 global $wgRequest, $wgUser, $wgOut, $wgMemc, $wgUserStatsTrackWeekly, $wgUserStatsTrackMonthly,
2020 $wgUserLevels, $wgUploadPath, $wgScriptPath;
2121
22 - // Read in localisation messages
23 - wfLoadExtensionMessages( 'SocialProfileUserStats' );
24 -
2522 // Load CSS
2623 $wgOut->addExtensionStyle( $wgScriptPath . '/extensions/SocialProfile/UserStats/TopList.css' );
2724
Index: trunk/extensions/SocialProfile/UserStats/TopFansByStat.php
@@ -18,9 +18,6 @@
1919 global $wgRequest, $wgUser, $wgOut, $wgMemc, $wgUserStatsTrackWeekly, $wgUserStatsTrackMonthly,
2020 $wgUserLevels, $wgUploadPath, $wgScriptPath;
2121
22 - // Read in localisation messages
23 - wfLoadExtensionMessages( 'SocialProfileUserStats' );
24 -
2522 // Load CSS
2623 $wgOut->addExtensionStyle( $wgScriptPath . '/extensions/SocialProfile/UserStats/TopList.css' );
2724
Index: trunk/extensions/SocialProfile/UserStats/UserStatsClass.php
@@ -550,7 +550,6 @@
551551 // Check if user advanced on this update
552552 if ( $level_number_after > $level_number_before ) {
553553 $m = new UserSystemMessage();
554 - wfLoadExtensionMessages( 'SocialProfileUserStats' );
555554 $m->addMessage( $this->user_name, 2, wfMsgForContent( 'level-advanced-to', $user_level->getLevelName() ) );
556555 $m->sendAdvancementNotificationEmail( $this->user_id, $user_level->getLevelName() );
557556 }
Index: trunk/extensions/SocialProfile/UserStats/TopUsers.php
@@ -17,9 +17,6 @@
1818 public function execute( $par ) {
1919 global $wgOut, $wgScriptPath, $wgMemc, $wgUserStatsTrackWeekly, $wgUserStatsTrackMonthly, $wgUserLevels, $wgUploadPath;
2020
21 - // Read in localisation messages
22 - wfLoadExtensionMessages( 'SocialProfileUserStats' );
23 -
2421 // Load CSS
2522 $wgOut->addExtensionStyle( $wgScriptPath . '/extensions/SocialProfile/UserStats/TopList.css' );
2623
Index: trunk/extensions/SocialProfile/UserProfile/SpecialPopulateExistingUsersProfiles.php
@@ -69,7 +69,6 @@
7070 }
7171 }
7272
73 - wfLoadExtensionMessages( 'SocialProfileUserProfile' );
7473 $wgOut->addHTML( wfMsgExt( 'populate-user-profile-done', 'parsemag', $count ) );
7574 }
7675 }
Index: trunk/extensions/SocialProfile/UserProfile/UserProfilePage.php
@@ -115,9 +115,6 @@
116116 function getUserStats( $user_id, $user_name ) {
117117 global $wgUserProfileDisplay;
118118
119 - // Load messages, we're gonna need 'em
120 - wfLoadExtensionMessages( 'SocialProfileUserProfile' );
121 -
122119 if ( $wgUserProfileDisplay['stats'] == false ) {
123120 return '';
124121 }
@@ -177,9 +174,6 @@
178175 function getProfileSection( $label, $value, $required = true ) {
179176 global $wgUser, $wgTitle, $wgOut;
180177
181 - // Load messages, we're gonna need 'em
182 - wfLoadExtensionMessages( 'SocialProfileUserProfile' );
183 -
184178 $output = '';
185179 if ( $value || $required ) {
186180 if ( !$value ) {
@@ -200,9 +194,6 @@
201195 function getPersonalInfo( $user_id, $user_name ) {
202196 global $wgUser, $wgUserProfileDisplay;
203197
204 - // Load messages, we're gonna need 'em
205 - wfLoadExtensionMessages( 'SocialProfileUserProfile' );
206 -
207198 if ( $wgUserProfileDisplay['personal'] == false ) {
208199 return '';
209200 }
@@ -381,9 +372,6 @@
382373 function getInterests( $user_name ) {
383374 global $wgUser, $wgUserProfileDisplay;
384375
385 - // Load messages, we're gonna need 'em
386 - wfLoadExtensionMessages( 'SocialProfileUserProfile' );
387 -
388376 if ( $wgUserProfileDisplay['interests'] == false ) {
389377 return '';
390378 }
@@ -451,9 +439,6 @@
452440 function getProfileTop( $user_id, $user_name ) {
453441 global $wgTitle, $wgUser, $wgUploadPath, $wgLang;
454442
455 - // Load messages, we're gonna need 'em
456 - wfLoadExtensionMessages( 'SocialProfileUserProfile' );
457 -
458443 $stats = new UserStats( $user_id, $user_name );
459444 $stats_data = $stats->getUserStats();
460445 $user_level = new UserLevel( $stats_data['points'] );
@@ -609,9 +594,6 @@
610595 function getRelationships( $user_name, $rel_type ) {
611596 global $wgMemc, $wgUser, $wgUserProfileDisplay, $wgUploadPath;
612597
613 - // Load messages, we're gonna need 'em
614 - wfLoadExtensionMessages( 'SocialProfileUserProfile' );
615 -
616598 // If not enabled in site settings, don't display
617599 if ( $rel_type == 1 ) {
618600 if ( $wgUserProfileDisplay['friends'] == false ) {
@@ -714,8 +696,6 @@
715697 return '';
716698 }
717699
718 - wfLoadExtensionMessages( 'SocialProfileUserProfile' );
719 -
720700 $output = '';
721701
722702 $limit = 8;
@@ -920,9 +900,6 @@
921901 function getGifts( $user_name ) {
922902 global $wgUser, $wgMemc, $wgUserProfileDisplay, $wgUploadPath;
923903
924 - // Load messages, we're gonna need 'em
925 - wfLoadExtensionMessages( 'SocialProfileUserProfile' );
926 -
927904 // If not enabled in site settings, don't display
928905 if ( $wgUserProfileDisplay['gifts'] == false ) {
929906 return '';
@@ -1004,9 +981,6 @@
1005982 function getAwards( $user_name ) {
1006983 global $wgUser, $wgMemc, $wgUserProfileDisplay, $wgUploadPath;
1007984
1008 - // Load messages, we're gonna need 'em
1009 - wfLoadExtensionMessages( 'SocialProfileUserProfile' );
1010 -
1011985 // If not enabled in site settings, don't display
1012986 if ( $wgUserProfileDisplay['awards'] == false ) {
1013987 return '';
@@ -1088,9 +1062,6 @@
10891063 function getUserBoard( $user_id, $user_name ) {
10901064 global $wgUser, $wgOut, $wgUserProfileDisplay, $wgUserProfileScripts;
10911065
1092 - // Load messages, we're gonna need 'em
1093 - wfLoadExtensionMessages( 'SocialProfileUserProfile' );
1094 -
10951066 if ( $user_id == 0 ) {
10961067 return '';
10971068 }
@@ -1150,8 +1121,6 @@
11511122
11521123 if ( $wgUser->getName() !== $user_name ) {
11531124 if ( $wgUser->isLoggedIn() && !$wgUser->isBlocked() ) {
1154 - // Some nice message in a other part of the extension :)
1155 - wfLoadExtensionMessages( 'SocialProfileUserBoard' );
11561125 $output .= '<div class="user-page-message-form">
11571126 <input type="hidden" id="user_name_to" name="user_name_to" value="' . addslashes( $user_name ) . '" />
11581127 <span style="color:#797979;">' . wfMsgHtml( 'userboard_messagetype' ) . '</span>
@@ -1194,8 +1163,6 @@
11951164 $wgOut->addScriptFile( $wgFanBoxScripts . '/FanBoxes.js' );
11961165 $wgOut->addExtensionStyle( $wgFanBoxScripts . '/FanBoxes.css' );
11971166
1198 - wfLoadExtensionMessages( 'FanBox' );
1199 -
12001167 $output = '';
12011168 $f = new UserFanBoxes( $user_name );
12021169 $user_safe = ( $user_name );
Index: trunk/extensions/SocialProfile/UserProfile/SpecialRemoveAvatar.php
@@ -16,7 +16,6 @@
1717 */
1818 public function execute( $user ) {
1919 global $wgUser, $wgOut, $wgRequest, $wgUploadAvatarInRecentChanges;
20 - wfLoadExtensionMessages( 'SocialProfileUserProfile' );
2120
2221 $this->title = SpecialPage::getTitleFor( 'RemoveAvatar' );
2322
Index: trunk/extensions/SocialProfile/UserProfile/SpecialUpdateProfile.php
@@ -46,8 +46,6 @@
4747 global $wgUser, $wgOut, $wgRequest, $wgUserProfileScripts, $wgUpdateProfileInRecentChanges, $wgSupressPageTitle;
4848 $wgSupressPageTitle = true;
4949
50 - wfLoadExtensionMessages( 'SocialProfileUserProfile' );
51 -
5250 $wgOut->setHTMLTitle( wfMsg( 'pagetitle', wfMsg( 'edit-profile-title' ) ) );
5351
5452 // This feature is only available for logged-in users.
@@ -348,8 +346,6 @@
349347 $websites = $s->up_websites;
350348 }
351349
352 - wfLoadExtensionMessages( 'SocialProfileUserProfile' );
353 -
354350 if ( !$location_country ) {
355351 $location_country = wfMsgForContent( 'user-profile-default-country' );
356352 }
@@ -545,8 +541,6 @@
546542 $drinks = $s->up_drinks;
547543 }
548544
549 - wfLoadExtensionMessages( 'SocialProfileUserProfile' );
550 -
551545 $wgOut->setPageTitle( wfMsg( 'user-profile-section-interests' ) );
552546 $form = UserProfile::getEditProfileNav( wfMsg( 'user-profile-section-interests' ) );
553547 $form .= '<form action="" method="post" enctype="multipart/form-data" name="profile">
@@ -607,8 +601,6 @@
608602 function displayPreferencesForm() {
609603 global $wgUser, $wgOut;
610604
611 - wfLoadExtensionMessages( 'SocialProfileUserProfile' );
612 -
613605 // @todo If the checkboxes are in front of the option, this would look more like Special:Preferences
614606 $wgOut->setPageTitle( wfMsg( 'user-profile-section-preferences' ) );
615607 $form = UserProfile::getEditProfileNav( wfMsg( 'user-profile-section-preferences' ) );
@@ -668,8 +660,6 @@
669661 $custom4 = $s->up_custom_4;
670662 }
671663
672 - wfLoadExtensionMessages( 'SocialProfileUserProfile' );
673 -
674664 $wgOut->setHTMLTitle( wfMsg( 'pagetitle', wfMsg( 'user-profile-tidbits-title' ) ) );
675665 $form = '<h1>' . wfMsg( 'user-profile-tidbits-title' ) . '</h1>';
676666 $form .= UserProfile::getEditProfileNav( wfMsg( 'user-profile-section-custom' ) );
Index: trunk/extensions/SocialProfile/UserProfile/SpecialUploadAvatar.php
@@ -65,8 +65,6 @@
6666 function showSuccess( $ext ) {
6767 global $wgUser, $wgOut, $wgContLang, $wgDBname, $wgUploadPath, $wgUploadAvatarInRecentChanges;
6868
69 - wfLoadExtensionMessages( 'SocialProfileUserProfile' );
70 -
7169 $log = new LogPage( wfMsgForContent( 'user-profile-picture-log' ) );
7270 if ( !$wgUploadAvatarInRecentChanges ) {
7371 $log->updateRecentChanges = false;
@@ -174,8 +172,6 @@
175173 ? 'checked="checked"'
176174 : '';
177175
178 - wfLoadExtensionMessages( 'SocialProfileUserProfile' );
179 -
180176 $output = '<h1>' . wfMsg( 'user-profile-picture-title' ) . '</h1>';
181177 $output .= UserProfile::getEditProfileNav( wfMsg( 'user-profile-section-picture' ) );
182178 $output .= '<div class="profile-info">';
Index: trunk/extensions/SocialProfile/UserRelationship/SpecialViewRelationshipRequests.php
@@ -25,7 +25,6 @@
2626 */
2727 public function execute( $params ) {
2828 global $wgUser, $wgOut, $wgRequest, $wgUserRelationshipScripts;
29 - wfLoadExtensionMessages( 'SocialProfileUserRelationship' );
3029
3130 /**
3231 * Redirect Non-logged in users to Login Page
Index: trunk/extensions/SocialProfile/UserRelationship/SpecialAddRelationship.php
@@ -29,7 +29,6 @@
3030 public function execute( $params ) {
3131 global $wgUser, $wgOut, $wgRequest, $wgUploadPath, $wgUserRelationshipScripts;
3232
33 - wfLoadExtensionMessages( 'SocialProfileUserRelationship' );
3433 $this->setHeaders();
3534
3635 $wgOut->addExtensionStyle( $wgUserRelationshipScripts . '/UserRelationship.css' );
@@ -210,7 +209,6 @@
211210 */
212211 function displayForm() {
213212 global $wgOut, $wgUploadPath;
214 - wfLoadExtensionMessages( 'SocialProfileUserRelationship' );
215213
216214 $form = '';
217215
Index: trunk/extensions/SocialProfile/UserRelationship/Relationship_AjaxFunctions.php
@@ -8,8 +8,6 @@
99 global $wgUser;
1010 $out = '';
1111
12 - wfLoadExtensionMessages( 'SocialProfileUserRelationship' );
13 -
1412 $rel = new UserRelationship( $wgUser->getName() );
1513 if ( $rel->verifyRelationshipRequest( $request_id ) == true ) {
1614 $request = $rel->getRequest( $request_id );
Index: trunk/extensions/SocialProfile/UserRelationship/SpecialRemoveRelationship.php
@@ -28,7 +28,6 @@
2929 public function execute( $params ) {
3030 global $wgUser, $wgOut, $wgRequest, $wgUploadPath, $wgUserRelationshipScripts;
3131
32 - wfLoadExtensionMessages( 'SocialProfileUserRelationship' );
3332 $this->setHeaders();
3433
3534 $wgOut->addExtensionStyle( $wgUserRelationshipScripts . '/UserRelationship.css' );
@@ -145,7 +144,6 @@
146145 */
147146 function displayForm() {
148147 global $wgOut, $wgUploadPath;
149 - wfLoadExtensionMessages( 'SocialProfileUserRelationship' );
150148
151149 $form = '';
152150 $avatar = new wAvatar( $this->user_id_to, 'l' );
Index: trunk/extensions/SocialProfile/UserRelationship/SpecialViewRelationships.php
@@ -28,8 +28,6 @@
2929 public function execute( $params ) {
3030 global $wgUser, $wgOut, $wgRequest, $wgUserRelationshipScripts, $wgLang;
3131
32 - wfLoadExtensionMessages( 'SocialProfileUserRelationship' );
33 -
3432 $wgOut->addExtensionStyle( $wgUserRelationshipScripts . '/UserRelationship.css' );
3533
3634 $output = '';
Index: trunk/extensions/SocialProfile/UserRelationship/UserRelationshipClass.php
@@ -14,7 +14,6 @@
1515 * @private
1616 */
1717 /* private */ function __construct( $username ) {
18 - wfLoadExtensionMessages( 'SocialProfileUserRelationship' );
1918 $title1 = Title::newFromDBkey( $username );
2019 $this->user_name = $title1->getText();
2120 $this->user_id = User::idFromName( $this->user_name );
Index: trunk/extensions/SocialProfile/SystemGifts/UserSystemGiftsClass.php
@@ -62,7 +62,6 @@
6363 $user = User::newFromId( $user_id_to );
6464 $user->loadFromDatabase();
6565 if ( $user->isEmailConfirmed() && $user->getIntOption( 'notifygift', 1 ) ) {
66 - wfLoadExtensionMessages( 'SystemGifts' );
6766 $gifts_link = SpecialPage::getTitleFor( 'ViewSystemGifts' );
6867 $update_profile_link = SpecialPage::getTitleFor( 'UpdateProfile' );
6968 $subject = wfMsgExt( 'system_gift_received_subject', 'parsemag',
Index: trunk/extensions/SocialProfile/SystemGifts/SpecialSystemGiftManager.php
@@ -16,7 +16,6 @@
1717 */
1818 public function execute( $par ) {
1919 global $wgUser, $wgOut, $wgRequest, $wgScriptPath, $wgSystemGiftsScripts;
20 - wfLoadExtensionMessages( 'SystemGifts' );
2120
2221 $wgOut->setPageTitle( wfMsg( 'systemgiftmanager' ) );
2322
Index: trunk/extensions/SocialProfile/SystemGifts/SpecialViewSystemGift.php
@@ -16,7 +16,6 @@
1717 */
1818 public function execute( $par ) {
1919 global $wgUser, $wgOut, $wgRequest, $wgUploadPath, $wgSystemGiftsScripts;
20 - wfLoadExtensionMessages( 'SystemGifts' );
2120
2221 $wgOut->addExtensionStyle( $wgSystemGiftsScripts . '/SystemGift.css' );
2322
Index: trunk/extensions/SocialProfile/SystemGifts/SpecialSystemGiftManagerLogo.php
@@ -405,7 +405,6 @@
406406 */
407407 function showSuccess( $status ) {
408408 global $wgUser, $wgOut, $wgUploadPath, $wgScriptPath, $wgLang;
409 - wfLoadExtensionMessages( 'SystemGifts' );
410409 $ext = 'jpg';
411410
412411 $output = '<h2>' . wfMsg( 'ga-uploadsuccess' ) . '</h2>';
@@ -457,7 +456,6 @@
458457 */
459458 function uploadError( $error ) {
460459 global $wgOut;
461 - wfLoadExtensionMessages( 'SystemGifts' );
462460 $sub = wfMsg( 'uploadwarning' );
463461 $wgOut->addHTML( "<h2>{$sub}</h2>\n" );
464462 $wgOut->addHTML( "<h4 class='error'>{$error}</h4>\n" );
@@ -534,7 +532,6 @@
535533 function mainUploadForm( $msg = '' ) {
536534 global $wgOut, $wgUser, $wgLang, $wgUploadDirectory, $wgRequest;
537535 global $wgUseCopyrightUpload;
538 - wfLoadExtensionMessages( 'SystemGifts' );
539536
540537 $cols = intval( $wgUser->getOption( 'cols' ) );
541538 $ew = $wgUser->getOption( 'editwidth' );
Index: trunk/extensions/SocialProfile/SystemGifts/SpecialViewSystemGifts.php
@@ -16,7 +16,6 @@
1717 */
1818 public function execute( $par ) {
1919 global $wgUser, $wgOut, $wgRequest, $wgMemc, $wgUploadPath, $wgSystemGiftsScripts;
20 - wfLoadExtensionMessages( 'SystemGifts' );
2120
2221 $wgOut->addExtensionStyle( $wgSystemGiftsScripts . '/SystemGift.css' );
2322
Index: trunk/extensions/SocialProfile/UserBoard/UserBoardClass.php
@@ -82,7 +82,6 @@
8383 if ( $user->isEmailConfirmed() && $user->getIntOption( 'notifymessage', 1 ) ) {
8484 $board_link = SpecialPage::getTitleFor( 'UserBoard' );
8585 $update_profile_link = SpecialPage::getTitleFor( 'UpdateProfile' );
86 - wfLoadExtensionMessages( 'SocialProfileUserBoard' );
8786 $subject = wfMsgExt( 'message_received_subject', 'parsemag',
8887 $user_from
8988 );
@@ -280,7 +279,6 @@
281280
282281 $output = ''; // Prevent E_NOTICE
283282 $messages = $this->getUserBoardMessages( $user_id, $user_id_2, $count, $page );
284 - wfLoadExtensionMessages( 'SocialProfileUserBoard' );
285283 if ( $messages ) {
286284
287285 foreach ( $messages as $message ) {
@@ -380,7 +378,6 @@
381379 }
382380
383381 public function getTimeOffset( $time, $timeabrv, $timename ) {
384 - wfLoadExtensionMessages( 'SocialProfileUserBoard' );
385382 $timeStr = '';
386383 if ( $time[$timeabrv] > 0 ) {
387384 $timeStr = wfMsgExt( "userboard-time-{$timename}", 'parsemag', $time[$timeabrv] );
Index: trunk/extensions/SocialProfile/UserBoard/SpecialUserBoard.php
@@ -29,8 +29,6 @@
3030 public function execute( $params ) {
3131 global $wgUser, $wgOut, $wgRequest, $wgScriptPath, $wgUserBoardScripts;
3232
33 - wfLoadExtensionMessages( 'SocialProfileUserBoard' );
34 -
3533 // Add CSS
3634 $wgOut->addExtensionStyle( $wgUserBoardScripts . '/UserBoard.css' );
3735
Index: trunk/extensions/SocialProfile/UserBoard/SpecialSendBoardBlast.php
@@ -30,8 +30,6 @@
3131 $wgOut->addExtensionStyle( $wgUserBoardScripts . '/BoardBlast.css' );
3232 $wgOut->addScriptFile( $wgUserBoardScripts . '/BoardBlast.js' );
3333
34 - wfLoadExtensionMessages( 'SocialProfileUserBoard' );
35 -
3634 $output = '';
3735
3836 // This feature is available only to logged-in users.

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r66934Large commit. Removed 800+ references to no-op wfLoadExtensionMessages()demon22:25, 26 May 2010

Status & tagging log