-
Notifications
You must be signed in to change notification settings - Fork 4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Error in displaying after re-login #8892
Comments
@tmatsuur, to clarify, is the code you provided in step two required or does it just make it easier to see the problem happen by shortening the login timeout? |
@designsimply sorry. It seems that the code did not break nicely and it became difficult to see. |
Adding a screenshot and noting some console errors: Seen at http://alittletestblog.com/wp-admin/post.php?post=13999&action=edit running WordPress 4.9.8 and Gutenberg 3.6.2 using Firefox 61.0.2 on macOS 10.13.6.
|
I think this was fixed by a recent update to how nonces work cc @ellatrix |
Session timeout while editing post.
After that, display the login form as a popup and login,
An error occurred when editing a new block.
The procedure is as follows.
1.Install WordPress 4.9.8. Then install and activate Gutenberg.
2.Added the following source code to functions.php of Twenty Seventeen.
function shorten_auth_cookie_expiration( $sec, $user_id, $remember ) { return 60; } add_filter( 'auth_cookie_expiration', 'shorten_auth_cookie_expiration', 10, 3 );
3.Log in to the admin page.
4.Click Posts > All Posts in the navigation.
5.Click 'Hello World!'.
6.Wait for the login form to pop up.
7.Enter your username and password to login.
8.Click the "Add block" area(Move the mouse pointer and the (+)mark is
displayed).
9.An error is displayed on the console.
GET http://local2/wp-json/wp/v2/types/wp_block?context=edit 403 (Forbidden) index.js?ver=1533789473:1 Uncaught (in promise) {code: "rest_cookie_invalid_nonce", message: "Cookie nonce is invalid", data: {…}}
OS: Windows 10
Browser: Chrome 68.0.3440.84, 68.0.3440.106
WordPress: 4.9.8
Gutenberg: 3.4.0, 3.5.0
The text was updated successfully, but these errors were encountered: