From 251ad300663608f6944ae4ee8d9e307ef5b2ef38 Mon Sep 17 00:00:00 2001 From: ryan Date: Wed, 9 Jan 2008 20:08:59 +0000 Subject: [PATCH] Call WP::init() just before kicking the init action so that the current user is setup as early as possible. fixes #4181 git-svn-id: http://svn.automattic.com/wordpress/trunk@6586 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-admin/admin.php | 2 -- wp-settings.php | 2 ++ 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/wp-admin/admin.php b/wp-admin/admin.php index e391e0eb2..26cce2725 100644 --- a/wp-admin/admin.php +++ b/wp-admin/admin.php @@ -19,8 +19,6 @@ nocache_headers(); update_category_cache(); -wp_get_current_user(); - $posts_per_page = get_option('posts_per_page'); $what_to_show = get_option('what_to_show'); $date_format = get_option('date_format'); diff --git a/wp-settings.php b/wp-settings.php index 84a0f36d5..f216783bb 100644 --- a/wp-settings.php +++ b/wp-settings.php @@ -438,6 +438,8 @@ function shutdown_action_hook() { } register_shutdown_function('shutdown_action_hook'); +$wp->init(); // Sets up current user. + // Everything is loaded and initialized. do_action('init');