diff --git a/wp-admin/includes/post.php b/wp-admin/includes/post.php index 1abe542316..ff3c8d269a 100644 --- a/wp-admin/includes/post.php +++ b/wp-admin/includes/post.php @@ -1399,6 +1399,7 @@ function get_sample_permalink( $post, $title = null, $name = null ) { $original_status = $post->post_status; $original_date = $post->post_date; $original_name = $post->post_name; + $original_filter = $post->filter; // Hack: get_permalink() would return plain permalink for drafts, so we will fake that our post is published. if ( in_array( $post->post_status, array( 'draft', 'pending', 'future' ), true ) ) { @@ -1443,7 +1444,7 @@ function get_sample_permalink( $post, $title = null, $name = null ) { $post->post_status = $original_status; $post->post_date = $original_date; $post->post_name = $original_name; - unset( $post->filter ); + $post->filter = $original_filter; /** * Filters the sample permalink. diff --git a/wp-includes/version.php b/wp-includes/version.php index 85ef16d436..5d0b99b121 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -16,7 +16,7 @@ * * @global string $wp_version */ -$wp_version = '6.1-alpha-54243'; +$wp_version = '6.1-alpha-54244'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.