WordPress.org

Make WordPress Core

Ticket #23317: media-views.2.diff

File media-views.2.diff, 626 bytes (added by kadamwhite, 5 years ago)

Flipped operands of === per georgestephanis

  • wp-includes/js/media-views.js

     
    24282428                                var requires = button.options.requires,
    24292429                                        disabled = false;
    24302430
     2431                                // Prevent insertion of attachments if any of them are still uploading
     2432                                disabled = _.some( selection.models, function( attachment ) {
     2433                                        return true === attachment.get('uploading');
     2434                                });
     2435
    24312436                                if ( requires.selection && selection && ! selection.length )
    24322437                                        disabled = true;
    24332438                                else if ( requires.library && library && ! library.length )