Make WordPress Core

Ticket #45516: 45516.patch

File 45516.patch, 562 bytes (added by rajanit2000, 6 years ago)

Add default title option

  • src/wp-admin/includes/post.php

     
    637637        }
    638638
    639639        if ( $create_in_db ) {
     640                $default_title = post_type_supports( $post_type, 'title' ) ? __( 'Auto Draft' ) : __( '(no title)' );
    640641                $post_id = wp_insert_post(
    641642                        array(
    642                                 'post_title'  => __( 'Auto Draft' ),
     643                                'post_title'  => $default_title,
    643644                                'post_type'   => $post_type,
    644645                                'post_status' => 'auto-draft',
    645646                        )