Allow plugins to handle admin page access failures. Fixes #5379 props donncha
git-svn-id: http://svn.automattic.com/wordpress/trunk@6356 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
0ad360cc00
commit
63c48d25b9
|
@ -137,6 +137,7 @@ unset($id);
|
|||
uksort($menu, "strnatcasecmp"); // make it all pretty
|
||||
|
||||
if (! user_can_access_admin_page()) {
|
||||
do_action('admin_page_access_denied');
|
||||
wp_die( __('You do not have sufficient permissions to access this page.') );
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue