Media JS: Ensure the subtype key has a default set.

Prevents undefined JS errors in the attachments view template.

see #21390.


git-svn-id: http://core.svn.wordpress.org/trunk@22160 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Daryl Koopersmith 2012-10-10 10:08:43 +00:00
parent 38b0a99f26
commit ebe800de42
2 changed files with 2 additions and 3 deletions

View File

@ -409,7 +409,8 @@
options = _.defaults( this.model.toJSON(), {
orientation: 'landscape',
uploading: false,
type: ''
type: '',
subtype: ''
});
options.buttons = this.buttons;

View File

@ -1340,8 +1340,6 @@ function wp_print_media_templates( $attachment ) {
<div class="filename"><%- filename %></div>
<% } %>
<% if ( buttons.close ) { %>
<a class="close" href="#">&times;</a>
<% } %>