Don't fall back to logged in cookie if in the admin.
git-svn-id: https://develop.svn.wordpress.org/trunk@12408 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
f14b014d58
commit
60a2805b0d
|
@ -99,7 +99,7 @@ function get_currentuserinfo() {
|
||||||
return;
|
return;
|
||||||
|
|
||||||
if ( ! $user = wp_validate_auth_cookie() ) {
|
if ( ! $user = wp_validate_auth_cookie() ) {
|
||||||
if ( empty($_COOKIE[LOGGED_IN_COOKIE]) || !$user = wp_validate_auth_cookie($_COOKIE[LOGGED_IN_COOKIE], 'logged_in') ) {
|
if ( is_admin() || empty($_COOKIE[LOGGED_IN_COOKIE]) || !$user = wp_validate_auth_cookie($_COOKIE[LOGGED_IN_COOKIE], 'logged_in') ) {
|
||||||
wp_set_current_user(0);
|
wp_set_current_user(0);
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue