- Timestamp:
- 05/16/2017 12:19:04 PM (9 years ago)
- Location:
- branches/4.1
- Files:
-
- 2 edited
-
. (modified) (1 prop)
-
src/wp-includes/class-wp-customize-manager.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
branches/4.1
-
branches/4.1/src/wp-includes/class-wp-customize-manager.php
r31410 r40711 176 176 $this->theme = wp_get_theme( isset( $_REQUEST['theme'] ) ? $_REQUEST['theme'] : null ); 177 177 178 /* 179 * Clear incoming post data if the user lacks a CSRF token (nonce). Note that the customizer 180 * application will inject the customize_preview_nonce query parameter into all Ajax requests. 181 * For similar behavior elsewhere in WordPress, see rest_cookie_check_errors() which logs out 182 * a user when a valid nonce isn't present. 183 */ 184 $has_post_data_nonce = ( 185 check_ajax_referer( 'preview-customize_' . $this->get_stylesheet(), 'nonce', false ) 186 || 187 check_ajax_referer( 'save-customize_' . $this->get_stylesheet(), 'nonce', false ) 188 || 189 check_ajax_referer( 'preview-customize_' . $this->get_stylesheet(), 'customize_preview_nonce', false ) 190 ); 191 if ( ! $has_post_data_nonce ) { 192 unset( $_POST['customized'] ); 193 unset( $_REQUEST['customized'] ); 194 } 195 178 196 if ( $this->is_theme_active() ) { 179 197 // Once the theme is loaded, we'll validate it.
Note:
See TracChangeset
for help on using the changeset viewer.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)