Skip to content
This repository has been archived by the owner on Dec 16, 2022. It is now read-only.

Commit

Permalink
Merge c66b957 into 27c468f
Browse files Browse the repository at this point in the history
  • Loading branch information
westonruter committed Jul 14, 2016
2 parents 27c468f + c66b957 commit 56fbfad
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions php/class-wp-customize-posts.php
Expand Up @@ -842,6 +842,10 @@ public function insert_auto_draft_post( $post_type ) {
'post_date_gmt' => $date_gmt,
'post_modified' => $date_local,
'post_modified_gmt' => $date_gmt,
'meta_input' => array(
// Dummy postmeta so that snapshot meta queries won't fail in \WP_Customize_Posts_Preview::get_previewed_posts_for_query().
'_snapshot_auto_draft' => true,
),
);
$r = wp_insert_post( wp_slash( $args ), true );
remove_filter( 'wp_insert_post_empty_content', '__return_false', 100 );
Expand Down

0 comments on commit 56fbfad

Please sign in to comment.