Skip to content

Commit d9d9d62

Browse files
Clarify deprecation messages by specifying the plugin name and version in do_action_deprecated calls.
1 parent db77505 commit d9d9d62

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

admin-functions.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -744,10 +744,10 @@ function duplicate_post_create_duplicate( $post, $status = '', $parent_id = '' )
744744

745745
// Deprecated hooks for backward compatibility.
746746
if ( $post->post_type === 'page' || is_post_type_hierarchical( $post->post_type ) ) {
747-
do_action_deprecated( 'dp_duplicate_page', [ $new_post_id, $post, $status ], '4.6', 'duplicate_post_after_duplicated' );
747+
do_action_deprecated( 'dp_duplicate_page', [ $new_post_id, $post, $status ], 'Yoast Duplicate Post 4.6', 'duplicate_post_after_duplicated' );
748748
}
749749
else {
750-
do_action_deprecated( 'dp_duplicate_post', [ $new_post_id, $post, $status ], '4.6', 'duplicate_post_after_duplicated' );
750+
do_action_deprecated( 'dp_duplicate_post', [ $new_post_id, $post, $status ], 'Yoast Duplicate Post 4.6', 'duplicate_post_after_duplicated' );
751751
}
752752

753753
delete_post_meta( $new_post_id, '_dp_original' );

0 commit comments

Comments
 (0)