Index: trunk/extensions/PageSchemas/specials/PS_EditSchema.php |
— | — | @@ -459,9 +459,10 @@ |
460 | 460 | function execute( $category ) { |
461 | 461 | global $wgRequest, $wgOut, $wgUser, $wgTitle; |
462 | 462 | |
463 | | - // Only display this page if user is allowed to edit the |
464 | | - // category page. |
465 | | - if ( !$wgUser->isAllowed( 'edit' ) || !$wgTitle->userCan( 'edit' ) ) { |
| 463 | + // If a category has been selected (i.e., it's not just |
| 464 | + // Special:EditSchema), only display this if the user is |
| 465 | + // allowed to edit the category page. |
| 466 | + if ( !is_null( $category ) && ( !$wgUser->isAllowed( 'edit' ) || !$wgTitle->userCan( 'edit' ) ) ) { |
466 | 467 | $wgOut->permissionRequired( 'edit' ); |
467 | 468 | return; |
468 | 469 | } |