Merge "StringStream::copyToStream() should adjust the offset"
[lhc/web/wiklou.git] / includes / htmlform / HTMLFormField.php
index 5f99aa0..16dc465 100644 (file)
@@ -137,8 +137,7 @@ abstract class HTMLFormField {
                for ( $i = count( $thisKeys ) - 1; $i >= 0; $i-- ) {
                        $keys = array_merge( array_slice( $thisKeys, 0, $i ), $nameKeys );
                        $data = $alldata;
-                       while ( $keys ) {
-                               $key = array_shift( $keys );
+                       foreach ( $keys as $key ) {
                                if ( !is_array( $data ) || !array_key_exists( $key, $data ) ) {
                                        continue 2;
                                }
@@ -587,7 +586,7 @@ abstract class HTMLFormField {
                        // It might look weird, but it'll work OK.
                        return $this->getFieldLayoutOOUI(
                                new OOUI\Widget( [ 'content' => new OOUI\HtmlSnippet( $this->getDiv( $value ) ) ] ),
-                               [ 'infusable' => false, 'align' => 'top' ]
+                               [ 'align' => 'top' ]
                        );
                }