From ec3d11986138286de04e0d4aee1a1df37cc59f65 Mon Sep 17 00:00:00 2001 From: Sergey Biryukov Date: Mon, 30 Jun 2014 14:39:17 +0000 Subject: [PATCH] Avoid overwriting $error global with an interim variable. props MikeLittle. fixes #28691. Built from https://develop.svn.wordpress.org/trunk@28925 git-svn-id: http://core.svn.wordpress.org/trunk@28724 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-login.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/wp-login.php b/wp-login.php index 257655891b..fe86fa1278 100644 --- a/wp-login.php +++ b/wp-login.php @@ -172,12 +172,12 @@ function login_header( $title = 'Log In', $message = '', $wp_error = '' ) { $errors = ''; $messages = ''; foreach ( $wp_error->get_error_codes() as $code ) { - $severity = $wp_error->get_error_data($code); - foreach ( $wp_error->get_error_messages($code) as $error ) { + $severity = $wp_error->get_error_data( $code ); + foreach ( $wp_error->get_error_messages( $code ) as $error_message ) { if ( 'message' == $severity ) - $messages .= ' ' . $error . "
\n"; + $messages .= ' ' . $error_message . "
\n"; else - $errors .= ' ' . $error . "
\n"; + $errors .= ' ' . $error_message . "
\n"; } } if ( ! empty( $errors ) ) {