From a9e592f1799538a99275f838a95729fc044dddee Mon Sep 17 00:00:00 2001 From: Maarten Bruna <14947039+ictbeheer@users.noreply.github.com> Date: Mon, 9 Feb 2026 09:47:50 +0100 Subject: [PATCH] fix: create post revision for rewrite copy --- src/post-duplicator.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/post-duplicator.php b/src/post-duplicator.php index ccb6e836a..33d1d61e4 100644 --- a/src/post-duplicator.php +++ b/src/post-duplicator.php @@ -173,6 +173,8 @@ public function create_duplicate_for_rewrite_and_republish( WP_Post $post ) { \update_post_meta( $new_post_id, '_dp_creation_date_gmt', \current_time( 'mysql', 1 ) ); } + wp_save_post_revision( $new_post_id ); + return $new_post_id; }