rebase on oct-10-2023
This commit is contained in:
@@ -34,7 +34,7 @@ if ( isset( $_REQUEST['action'] ) && 'adduser' === $_REQUEST['action'] ) {
|
||||
|
||||
$user_details = null;
|
||||
$user_email = wp_unslash( $_REQUEST['email'] );
|
||||
if ( false !== strpos( $user_email, '@' ) ) {
|
||||
if ( str_contains( $user_email, '@' ) ) {
|
||||
$user_details = get_user_by( 'email', $user_email );
|
||||
} else {
|
||||
if ( current_user_can( 'manage_network_users' ) ) {
|
||||
@@ -566,18 +566,18 @@ if ( current_user_can( 'create_users' ) ) {
|
||||
</label>
|
||||
</th>
|
||||
<td>
|
||||
<input class="hidden" value=" " /><!-- #24364 workaround -->
|
||||
<input type="hidden" value=" " /><!-- #24364 workaround -->
|
||||
<button type="button" class="button wp-generate-pw hide-if-no-js"><?php _e( 'Generate password' ); ?></button>
|
||||
<div class="wp-pwd">
|
||||
<?php $initial_password = wp_generate_password( 24 ); ?>
|
||||
<span class="password-input-wrapper">
|
||||
<div class="password-input-wrapper">
|
||||
<input type="password" name="pass1" id="pass1" class="regular-text" autocomplete="new-password" spellcheck="false" data-reveal="1" data-pw="<?php echo esc_attr( $initial_password ); ?>" aria-describedby="pass-strength-result" />
|
||||
</span>
|
||||
<div style="display:none" id="pass-strength-result" aria-live="polite"></div>
|
||||
</div>
|
||||
<button type="button" class="button wp-hide-pw hide-if-no-js" data-toggle="0" aria-label="<?php esc_attr_e( 'Hide password' ); ?>">
|
||||
<span class="dashicons dashicons-hidden" aria-hidden="true"></span>
|
||||
<span class="text"><?php _e( 'Hide' ); ?></span>
|
||||
</button>
|
||||
<div style="display:none" id="pass-strength-result" aria-live="polite"></div>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
Reference in New Issue
Block a user