Ticket #35662: 35662.diff
File 35662.diff, 753 bytes (added by , 9 years ago) |
---|
-
src/wp-includes/rest-api/class-wp-rest-server.php
251 251 } 252 252 253 253 /** 254 * Send a refreshed nonce header on authenticated requests. 255 * 256 * @since 4.5.0 257 * 258 * @param bool $rest_send_refreshed_nonce Whether to send a refreshed nonce in the response headers. 259 */ 260 $rest_send_refreshed_nonce = apply_filters( 'rest_send_refreshed_nonce', is_user_logged_in() ); 261 $this->send_header( 'X-WP-Nonce', wp_create_nonce( 'wp_rest' ) ); 262 263 /** 254 264 * Filter whether the REST API is enabled. 255 265 * 256 266 * @since 4.4.0