diff --git a/wp-admin/includes/media.php b/wp-admin/includes/media.php index 8e6d75eb4f..8da6506e99 100644 --- a/wp-admin/includes/media.php +++ b/wp-admin/includes/media.php @@ -278,7 +278,7 @@ function media_handle_upload($file_id, $post_id, $post_data = array(), $override $url = $file['url']; $type = $file['type']; $file = $file['file']; - $title = sanitize_title( $name ); + $title = sanitize_text_field( $name ); $content = ''; $excerpt = '';