WordPress.org

Make WordPress Core

Ticket #41135: 41135-backport-37697-4-5.patch

File 41135-backport-37697-4-5.patch, 855 bytes (added by ayeshrajans, 2 years ago)

Changeset 37697 backport for 4.5 branch

  • wp-includes/user.php

    diff --git a/wp-includes/user.php b/wp-includes/user.php
    index 69cc86c0d..b2828d844 100644
    a b  
    2727 */
    2828function wp_signon( $credentials = array(), $secure_cookie = '' ) {
    2929        if ( empty($credentials) ) {
     30                $credentials = array(); // Back-compat for plugins passing an empty string.
     31
    3032                if ( ! empty($_POST['log']) )
    3133                        $credentials['user_login'] = $_POST['log'];
    3234                if ( ! empty($_POST['pwd']) )
  • wp-login.php

    diff --git a/wp-login.php b/wp-login.php
    index ed3878c29..b407ce415 100644
    a b function retrieve_password() { 
    781781
    782782        $reauth = empty($_REQUEST['reauth']) ? false : true;
    783783
    784         $user = wp_signon( '', $secure_cookie );
     784        $user = wp_signon( array(), $secure_cookie );
    785785
    786786        if ( empty( $_COOKIE[ LOGGED_IN_COOKIE ] ) ) {
    787787                if ( headers_sent() ) {