Widgets: Allow deletion even when widget form fails validity checks.
Props felipeelia. Amends [41352]. See #23120. Fixes #42127. git-svn-id: https://develop.svn.wordpress.org/trunk@41813 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
cdba279149
commit
6bbf13852b
@ -515,7 +515,7 @@ wpWidgets = {
|
||||
sidebarId = widget.closest( 'div.widgets-sortables' ).attr( 'id' ),
|
||||
form = widget.find( 'form' );
|
||||
|
||||
if ( form.prop( 'checkValidity' ) && ! form[0].checkValidity() ) {
|
||||
if ( ! del && form.prop( 'checkValidity' ) && ! form[0].checkValidity() ) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user