mirror of
https://github.com/WordPress/WordPress.git
synced 2024-10-05 11:07:44 +02:00
Don't allow images to be set as featured image until they have been processed.
props kadamwhite. fixes #23317. git-svn-id: http://core.svn.wordpress.org/trunk@23956 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
bf12a91981
commit
262b3bd9b1
@ -2428,6 +2428,11 @@
|
|||||||
var requires = button.options.requires,
|
var requires = button.options.requires,
|
||||||
disabled = false;
|
disabled = false;
|
||||||
|
|
||||||
|
// Prevent insertion of attachments if any of them are still uploading
|
||||||
|
disabled = _.some( selection.models, function( attachment ) {
|
||||||
|
return attachment.get('uploading') === true;
|
||||||
|
});
|
||||||
|
|
||||||
if ( requires.selection && selection && ! selection.length )
|
if ( requires.selection && selection && ! selection.length )
|
||||||
disabled = true;
|
disabled = true;
|
||||||
else if ( requires.library && library && ! library.length )
|
else if ( requires.library && library && ! library.length )
|
||||||
|
Loading…
Reference in New Issue
Block a user