Customizer: Don't query for postmeta for Custom CSS (for not-current-themes) and Customizer Changeset posts.

Props dlh.
Merges [39692] to the 4.7 branch.
Fixes #39194.


git-svn-id: https://develop.svn.wordpress.org/branches/4.7@39693 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Dion Hulse 2017-01-05 08:12:06 +00:00
parent e1c6f72330
commit dd41ff6c2c
2 changed files with 4 additions and 2 deletions

View File

@ -798,7 +798,8 @@ final class WP_Customize_Manager {
'no_found_rows' => true,
'cache_results' => true,
'update_post_meta_cache' => false,
'update_term_meta_cache' => false,
'update_post_term_cache' => false,
'lazy_load_term_meta' => false,
) );
if ( ! empty( $changeset_post_query->posts ) ) {
// Note: 'fields'=>'ids' is not being used in order to cache the post object as it will be needed.

View File

@ -1643,7 +1643,8 @@ function wp_get_custom_css_post( $stylesheet = '' ) {
'no_found_rows' => true,
'cache_results' => true,
'update_post_meta_cache' => false,
'update_term_meta_cache' => false,
'update_post_term_cache' => false,
'lazy_load_term_meta' => false,
);
$post = null;