Add a default post_title value to wp_insert_attachment() to avoid a notice when there is no ID3 title.
props wonderboymusic. see #24805. git-svn-id: http://core.svn.wordpress.org/trunk@24759 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
eb822723ae
commit
df0ac70aff
|
@ -3876,7 +3876,7 @@ function wp_insert_attachment($object, $file = false, $parent = 0) {
|
|||
global $wpdb, $user_ID;
|
||||
|
||||
$defaults = array('post_status' => 'inherit', 'post_type' => 'post', 'post_author' => $user_ID,
|
||||
'ping_status' => get_option('default_ping_status'), 'post_parent' => 0,
|
||||
'ping_status' => get_option('default_ping_status'), 'post_parent' => 0, 'post_title' => '',
|
||||
'menu_order' => 0, 'to_ping' => '', 'pinged' => '', 'post_password' => '',
|
||||
'guid' => '', 'post_content_filtered' => '', 'post_excerpt' => '', 'import_id' => 0, 'context' => '');
|
||||
|
||||
|
|
Loading…
Reference in New Issue