Because programming is fun. After [32915], `_.find()` will return `undefined` if an empty array is passed - in that case, the function should return `true`.
See #32746. Built from https://develop.svn.wordpress.org/trunk@32916 git-svn-id: http://core.svn.wordpress.org/trunk@32887 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
15bfe75f88
commit
8854256155
|
@ -900,7 +900,7 @@ var Attachments = Backbone.Collection.extend({
|
|||
mime = atts.mime || ( atts.file && atts.file.type ) || '';
|
||||
|
||||
if ( _.isArray( type ) ) {
|
||||
found = _.find( type, function (t) {
|
||||
found = ! type.length || _.find( type, function (t) {
|
||||
return -1 !== mime.indexOf( t );
|
||||
} );
|
||||
} else {
|
||||
|
|
File diff suppressed because one or more lines are too long
|
@ -4,7 +4,7 @@
|
|||
*
|
||||
* @global string $wp_version
|
||||
*/
|
||||
$wp_version = '4.3-alpha-32915';
|
||||
$wp_version = '4.3-alpha-32916';
|
||||
|
||||
/**
|
||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||
|
|
Loading…
Reference in New Issue