Commit 58db005b authored by drumm's avatar drumm
Browse files

Forward port from 4.7

#60797, moved comment, patch by Zen
parent d6b538ef
......@@ -504,6 +504,7 @@ function form_render(&$elements) {
$previous_value = $elements['#value'];
$previous_type = $elements['#type'];
// If we rendered a single element, then we will skip the renderer.
if (empty($children)) {
$elements['#printed'] = TRUE;
}
......@@ -516,7 +517,6 @@ function form_render(&$elements) {
$elements['#value'] = $previous_value;
$elements['#type'] = $previous_type;
// if we rendered a single element, then we will skip the renderer
unset($elements['#prefix'], $elements['#suffix']);
}
/* render each of the children using form_render and concatenate them */
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment