Index: trunk/phase3/includes/SpecialPage.php |
— | — | @@ -365,15 +365,16 @@ |
366 | 366 | /** |
367 | 367 | * Add a page to a certain display group for Special:SpecialPages |
368 | 368 | * |
369 | | - * @param SpecialPage $page |
| 369 | + * @param mixed $page (SpecialPage or string) |
370 | 370 | * @param string $group |
371 | 371 | * @static |
372 | 372 | */ |
373 | | - static function setGroup( &$page, $group ) { |
| 373 | + static function setGroup( $page, $group ) { |
374 | 374 | if ( !self::$mListInitialised ) { |
375 | 375 | self::initList(); |
376 | 376 | } |
377 | | - self::$mGroupsList[$page->mName] = $group; |
| 377 | + $name = is_object($page) ? $page->mName : $page; |
| 378 | + self::$mGroupsList[$name] = $group; |
378 | 379 | } |
379 | 380 | |
380 | 381 | /** |