Index: trunk/extensions/SocialProfile/SocialProfile.php |
— | — | @@ -101,7 +101,8 @@ |
102 | 102 | |
103 | 103 | // Should we enable UserStatus feature (currently is under development) |
104 | 104 | $wgEnableUserStatus = false; |
105 | | - |
| 105 | +// Permission to delete other Users' Status Messages |
| 106 | +$wgGroupPermissions['sysop']['delete-status-update'] = true; |
106 | 107 | // Extension credits that show up on Special:Version |
107 | 108 | $wgExtensionCredits['other'][] = array( |
108 | 109 | 'path' => __FILE__, |
Index: trunk/extensions/SocialProfile/UserStatus/SpecialUserStatus.php |
— | — | @@ -13,12 +13,13 @@ |
14 | 14 | } |
15 | 15 | |
16 | 16 | public function execute( $params ) { |
17 | | - global $wgOut; |
18 | | - |
19 | | - $output = "Enter username: <input type=\"text\" id=\"us-name-input\"> "; |
20 | | - $output .= "<input type=\"button\" value=\"Find\" onclick=\"javascript:UserStatus.specialGetHistory();\">"; |
21 | | - $output .= "<div id=\"us-special\"> </div>"; |
22 | | - $wgOut->addHTML($output); |
| 17 | + global $wgOut,$wgUser; |
| 18 | + if ( $wgUser->isAllowed( 'delete-status-update' ) ) { |
| 19 | + $output = "Enter username: <input type=\"text\" id=\"us-name-input\"> "; |
| 20 | + $output .= "<input type=\"button\" value=\"Find\" onclick=\"javascript:UserStatus.specialGetHistory();\">"; |
| 21 | + $output .= "<div id=\"us-special\"> </div>"; |
| 22 | + $wgOut->addHTML($output); |
| 23 | + } |
23 | 24 | return; |
24 | 25 | } |
25 | 26 | |