From df0ac70aff24949433073f7345d2d454e0de6ba9 Mon Sep 17 00:00:00 2001 From: Andrew Nacin Date: Sat, 20 Jul 2013 20:20:47 +0000 Subject: [PATCH] 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 --- wp-includes/post.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/wp-includes/post.php b/wp-includes/post.php index eb636864e5..c8888c6ede 100644 --- a/wp-includes/post.php +++ b/wp-includes/post.php @@ -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' => '');