Posts, Post Types: Use `COOKIEPATH` when clearing post password cookie, as that's the path it's created with.

See #44089.

git-svn-id: https://develop.svn.wordpress.org/trunk@43318 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Sergey Biryukov 2018-05-27 01:32:20 +00:00
parent daf0333601
commit 302a2297dd
1 changed files with 1 additions and 1 deletions

View File

@ -978,7 +978,7 @@ if ( ! function_exists( 'wp_clear_auth_cookie' ) ) :
setcookie( PASS_COOKIE, ' ', time() - YEAR_IN_SECONDS, SITECOOKIEPATH, COOKIE_DOMAIN );
// Post password cookie
setcookie( 'wp-postpass_' . COOKIEHASH, ' ', time() - YEAR_IN_SECONDS, SITECOOKIEPATH, COOKIE_DOMAIN );
setcookie( 'wp-postpass_' . COOKIEHASH, ' ', time() - YEAR_IN_SECONDS, COOKIEPATH, COOKIE_DOMAIN );
}
endif;