summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--includes/form.inc3
1 files changed, 1 insertions, 2 deletions
diff --git a/includes/form.inc b/includes/form.inc
index 61c2261d6..202516960 100644
--- a/includes/form.inc
+++ b/includes/form.inc
@@ -503,6 +503,7 @@ function drupal_prepare_form($form_id, &$form, &$form_state) {
}
$form += _element_info('form');
+ $form += array('#tree' => FALSE, '#parents' => array());
if (!isset($form['#validate'])) {
if (drupal_function_exists($form_id . '_validate')) {
@@ -1328,8 +1329,6 @@ function _element_info($type, $refresh = NULL) {
'#description' => NULL,
'#attributes' => array(),
'#required' => FALSE,
- '#tree' => FALSE,
- '#parents' => array()
);
if (!isset($cache) || $refresh) {
$cache = array();