Index: trunk/extensions/Renameuser/Renameuser_body.php |
— | — | @@ -274,7 +274,7 @@ |
275 | 275 | // Move any user pages |
276 | 276 | if ( $wgRequest->getCheck( 'movepages' ) && $wgUser->isAllowed( 'move' ) ) { |
277 | 277 | $dbr = wfGetDB( DB_SLAVE ); |
278 | | - $oldkey = $oldusername->getDBkey(); |
| 278 | + |
279 | 279 | $pages = $dbr->select( |
280 | 280 | 'page', |
281 | 281 | array( 'page_namespace', 'page_title' ), |
— | — | @@ -285,9 +285,9 @@ |
286 | 286 | ), |
287 | 287 | __METHOD__ |
288 | 288 | ); |
289 | | - |
| 289 | + |
290 | 290 | $suppressRedirect = false; |
291 | | - |
| 291 | + |
292 | 292 | if ( $wgRequest->getCheck( 'suppressredirect' ) && $wgUser->isAllowed( 'suppressredirect' ) ) { |
293 | 293 | $suppressRedirect = true; |
294 | 294 | } |
— | — | @@ -325,6 +325,12 @@ |
326 | 326 | array( 'renameusersuccess', $oldusername->getText(), $newusername->getText() ) ); |
327 | 327 | } |
328 | 328 | |
| 329 | + /** |
| 330 | + * @param $username Title |
| 331 | + * @param $type |
| 332 | + * @param $out |
| 333 | + * @return void |
| 334 | + */ |
329 | 335 | function showLogExtract( $username, $type, &$out ) { |
330 | 336 | # Show relevant lines from the logs: |
331 | 337 | $out->addHTML( Xml::element( 'h2', null, LogPage::logName( $type ) ) . "\n" ); |
Index: trunk/extensions/Renameuser/Renameuser.php |
— | — | @@ -42,6 +42,15 @@ |
43 | 43 | # $wgLogActions['renameuser/renameuser'] = 'renameuserlogentry'; |
44 | 44 | $wgLogActionsHandlers['renameuser/renameuser'] = 'wfRenameUserLogActionText'; // deal with old breakage |
45 | 45 | |
| 46 | +/** |
| 47 | + * @param $type |
| 48 | + * @param $action |
| 49 | + * @param $title Title |
| 50 | + * @param $skin Skin |
| 51 | + * @param $params array |
| 52 | + * @param $filterWikilinks bool |
| 53 | + * @return String |
| 54 | + */ |
46 | 55 | function wfRenameUserLogActionText( $type, $action, $title = null, $skin = null, $params = array(), $filterWikilinks = false ) { |
47 | 56 | if ( !$title || $title->getNamespace() !== NS_USER ) { |
48 | 57 | $rv = ''; // handled in comment, the old way |
— | — | @@ -83,6 +92,12 @@ |
84 | 93 | return true; |
85 | 94 | } |
86 | 95 | |
| 96 | +/** |
| 97 | + * @param $id |
| 98 | + * @param $nt Title |
| 99 | + * @param $tools |
| 100 | + * @return bool |
| 101 | + */ |
87 | 102 | function wfRenameuserOnContribsLink( $id, $nt, &$tools ) { |
88 | 103 | global $wgUser; |
89 | 104 | |