Ticket #40803: 40803.1.diff
File 40803.1.diff, 905 bytes (added by , 8 years ago) |
---|
-
wp-admin/js/widgets/media-widgets.js
248 248 * @returns {void} 249 249 */ 250 250 createStates: function createStates() { 251 var mime = this.options.mimeType, specificMimes = [];252 _.each( wp.media.view.settings.embedMimes, function( embedMime ) {253 if ( 0 === embedMime.indexOf( mime ) ) {254 specificMimes.push( embedMime );255 }256 });257 if ( specificMimes.length > 0 ) {258 mime = specificMimes.join( ',' );259 }260 261 251 this.states.add([ 262 252 263 253 // Main states. … … 269 259 toolbar: 'main-insert', 270 260 filterable: 'dates', 271 261 library: wp.media.query({ 272 type: mime262 type: this.options.mimeType 273 263 }), 274 264 multiple: false, 275 265 editable: true,