]> scripts.mit.edu Git - autoinstalls/wordpress.git/blobdiff - wp-includes/js/wp-auth-check.js
WordPress 4.5
[autoinstalls/wordpress.git] / wp-includes / js / wp-auth-check.js
index 8b78de953f5156adf35b8a434a8b75b083a58216..9448a47ec7f722c1e53a321bbf530adccdcee7cc 100644 (file)
                        });
 
                        frame = $('<iframe id="wp-auth-check-frame" frameborder="0">').attr( 'title', noframe.text() );
-                       frame.load( function() {
+                       frame.on( 'load', function() {
                                var height, body;
 
                                loaded = true;
+                               // Remove the spinner to avoid unnecessary CPU/GPU usage.
+                               form.removeClass( 'loading' );
 
                                try {
                                        body = $(this).contents().find('body');
@@ -46,7 +48,7 @@
                                }
                        }).attr( 'src', form.data('src') );
 
-                       $('#wp-auth-check-form').append( frame );
+                       form.append( frame );
                }
 
                $( 'body' ).addClass( 'modal-open' );