From: Gergő Tisza Date: Fri, 1 Apr 2016 12:05:12 +0000 (+0300) Subject: Fix missing variable in HTMLFormField exceptions X-Git-Tag: 1.31.0-rc.0~7459^2 X-Git-Url: http://git.cyclocoop.org/%22%20.%20generer_url_ecrire%28%22brouteur%22%2C%28%24id_rubrique%20?a=commitdiff_plain;h=563830198a6aeb550cda8113bc51b2b16d76020b;p=lhc%2Fweb%2Fwiklou.git Fix missing variable in HTMLFormField exceptions Change-Id: Ie61f170e9117dde7ece05b04573a3c4902b19e56 --- diff --git a/includes/htmlform/HTMLFormField.php b/includes/htmlform/HTMLFormField.php index a9c76321d7..4c8ce82827 100644 --- a/includes/htmlform/HTMLFormField.php +++ b/includes/htmlform/HTMLFormField.php @@ -179,7 +179,7 @@ abstract class HTMLFormField { return true; case 'OR': - foreach ( $params as $p ) { + foreach ( $params as $i => $p ) { if ( !is_array( $p ) ) { throw new MWException( "Expected array, found " . gettype( $p ) . " at index $i" @@ -205,7 +205,7 @@ abstract class HTMLFormField { return false; case 'NOR': - foreach ( $params as $p ) { + foreach ( $params as $i => $p ) { if ( !is_array( $p ) ) { throw new MWException( "Expected array, found " . gettype( $p ) . " at index $i"