WordPress.org

Make WordPress Core

Ticket #12159: 12159.extraspecialchars.diff

File 12159.extraspecialchars.diff, 643 bytes (added by sivel, 8 years ago)

Remove $extra_special_chars out from within the $special_chars if statement, so that you can use $extra_special_chars without $special_chars

  • wp-includes/pluggable.php

     
    14681468 **/
    14691469function wp_generate_password( $length = 12, $special_chars = true, $extra_special_chars = false ) {
    14701470        $chars = 'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789';
    1471         if ( $special_chars ) {
     1471        if ( $special_chars )
    14721472                $chars .= '!@#$%^&*()';
    1473                 if ( $extra_special_chars )
     1473
     1474        if ( $extra_special_chars )
    14741475                        $chars .= '-_ []{}<>~`+=,.;:/?|';
    1475         }
    14761476
    14771477        $password = '';
    14781478        for ( $i = 0; $i < $length; $i++ ) {