Customize: Ensure customized changes pending to be written into changeset are successfully injected into Ajax requests in preview.

Amends [40704].
See #42162.


git-svn-id: https://develop.svn.wordpress.org/trunk@41804 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Weston Ruter
2017-10-10 04:50:37 +00:00
parent 52ef606823
commit 55f2dac880

View File

@@ -451,6 +451,10 @@
if ( ! api.settings.theme.active ) {
queryParams.customize_theme = api.settings.theme.stylesheet;
}
// Ensure preview nonce is included with every customized request, to allow post data to be read.
queryParams.customize_preview_nonce = api.settings.nonce.preview;
urlParser.search = $.param( queryParams );
options.url = urlParser.href;
};