'all_users', 'post_author' => 'current_user', 'status' => 'same', 'type' => 'same', 'timestamp' => 'current', 'title' => __('Copy', 'post-duplicator'), 'slug' => 'copy', 'time_offset' => false, 'time_offset_days' => 0, 'time_offset_hours' => 0, 'time_offset_minutes' => 0, 'time_offset_seconds' => 0, 'time_offset_direction' => 'newer' ); // Filter the settings $settings = apply_filters( 'mtphr_post_duplicator_settings', $settings ); // Return the settings return wp_parse_args( $settings, $defaults ); } function mtphr_post_duplicator_submitbox( $post ) { if( $post->post_status == 'publish' ) { $settings = get_mtphr_post_duplicator_settings(); if ( 'current_user' === $settings['post_duplication'] ) { if ( get_current_user_id() != $post->post_author ) { return false; } } $post_type = get_post_type_object( $post->post_type ); $nonce = wp_create_nonce( 'm4c_ajax_file_nonce' ); ?>
labels->singular_name ) ); ?>