Make WordPress Core

Ticket #41749: 41749.patch

File 41749.patch, 2.0 KB (added by umangvaghela123, 7 years ago)
  • wp-login.php

     
    4242                $wp_error = new WP_Error();
    4343
    4444        // Shake it!
    45         $shake_error_codes = array( 'empty_password', 'empty_email', 'invalid_email', 'invalidcombo', 'empty_username', 'invalid_username', 'incorrect_password' );
     45        $shake_error_codes = array( 'empty_password', 'empty_email', 'invalid_email', 'invalidcombo', 'empty_username', 'invalid_username', 'incorrect_password', );
    4646        /**
    4747         * Filters the error codes array for shaking the login form.
    4848         *
     
    377377        return true;
    378378}
    379379
    380 //
    381 // Main
    382 //
    383 
    384380$action = isset($_REQUEST['action']) ? $_REQUEST['action'] : 'login';
    385381$errors = new WP_Error();
    386382
     
    388384        $action = 'resetpass';
    389385
    390386// validate action so as to default to the login screen
    391 if ( !in_array( $action, array( 'postpass', 'logout', 'lostpassword', 'retrievepassword', 'resetpass', 'rp', 'register', 'login' ), true ) && false === has_filter( 'login_form_' . $action ) )
     387if ( !in_array( $action, array( 'postpass', 'logout', 'lostpassword', 'retrievepassword', 'resetpass', 'rp', 'register', 'login', ), true ) && false === has_filter( 'login_form_' . $action ) )
    392388        $action = 'login';
    393389
    394390nocache_headers();
  • wp-signup.php

     
    282282        $signup_defaults = array(
    283283                'blogname'   => $blogname,
    284284                'blog_title' => $blog_title,
    285                 'errors'     => $errors
     285                'errors'     => $errors,
    286286        );
    287287
    288288        /**
     
    378378
    379379        $blog_meta_defaults = array(
    380380                'lang_id' => 1,
    381                 'public'  => $public
     381                'public'  => $public,
    382382        );
    383383
    384384        // Handle the language setting for the new site.
     
    632632                'user_email' => $user_email,
    633633                'blogname'   => $blogname,
    634634                'blog_title' => $blog_title,
    635                 'errors'     => $errors
     635                'errors'     => $errors,
    636636        );
    637637
    638638        /**