Updates: Properly define `$filesystemForm` to handle error in modals.
Ammends [39657]. See #39057. git-svn-id: https://develop.svn.wordpress.org/trunk@39689 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
de72bafedc
commit
7cfb768da3
|
@ -1516,6 +1516,8 @@
|
||||||
* @param {string} message Error message.
|
* @param {string} message Error message.
|
||||||
*/
|
*/
|
||||||
wp.updates.showErrorInCredentialsForm = function( message ) {
|
wp.updates.showErrorInCredentialsForm = function( message ) {
|
||||||
|
var $filesystemForm = $( '#request-filesystem-credentials-form' );
|
||||||
|
|
||||||
// Remove any existing error.
|
// Remove any existing error.
|
||||||
$filesystemForm.find( '.notice' ).remove();
|
$filesystemForm.find( '.notice' ).remove();
|
||||||
$filesystemForm.find( '#request-filesystem-credentials-title' ).after( '<div class="notice notice-alt notice-error"><p>' + message + '</p></div>' );
|
$filesystemForm.find( '#request-filesystem-credentials-title' ).after( '<div class="notice notice-alt notice-error"><p>' + message + '</p></div>' );
|
||||||
|
|
Loading…
Reference in New Issue