Offset error if the first item in an admin menu is a separator
|Reported by:||phill_brown||Owned by:||markjaquith|
There are a few ways you can get to this error, but the easiest way with the default install is:
add_action( 'admin_menu', create_function( '', 'unset( $GLOBALS[\'menu\'] );' ) );
I originally came across the error assigning the manage_sites capability to a non super admin role. If you do the same and visit /wp-admin/network/sites.php - you'll see the same error.
If this fix is approved, it raises another minor issue with the network page. There's now an unnecessary separator at the top of the menu. The second patch (network-menu) assigns the same capability requirement to the separator as the dashboard.
Change History (8)
comment:1 SergeyBiryukov — 11 months ago
- Component changed from Menus to Warnings/Notices
- Milestone changed from Awaiting Review to 3.6
- Version changed from trunk to 2.7
comment:4 markjaquith — 6 months ago
- Owner set to markjaquith
- Resolution set to fixed
- Status changed from new to closed