Make WordPress Core

Changeset 49337


Ignore:
Timestamp:
10/27/2020 06:41:32 PM (4 years ago)
Author:
helen
Message:

Login: Avoid AJAX error on login screen.

This has to do with the password generator, which does not need to generate and cache passwords in JS as that's already done in PHP.

Props adamsilverstein, sarahricker.
Fixes #51613.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/js/_enqueues/admin/user-profile.js

    r49248 r49337  
    146146
    147147        bindToggleButton();
    148 
    149         // Generate the first password and cache it, but don't set it yet.
    150         wp.ajax.post( 'generate-password' )
    151             .done( function( data ) {
    152                 // Cache password.
    153                 $pass1.data( 'pw', data );
    154             } );
    155148
    156149        $generateButton.show();
Note: See TracChangeset for help on using the changeset viewer.