From a83e5605c763ddb2995cbec002576f29d75a9402 Mon Sep 17 00:00:00 2001 From: Dries Buytaert <dries@buytaert.net> Date: Wed, 12 Aug 2009 11:45:14 +0000 Subject: [PATCH] - Patch #546568 by quicksketch: consistently pass in to #value_callback functions. --- includes/form.inc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/form.inc b/includes/form.inc index 866ac2ba7985..6f7d96305473 100644 --- a/includes/form.inc +++ b/includes/form.inc @@ -1113,7 +1113,7 @@ function _form_builder_handle_input_element($form_id, &$element, &$form_state) { if (!isset($element['#value'])) { // Call #type_value without a second argument to request default_value handling. if (drupal_function_exists($value_callback)) { - $element['#value'] = $value_callback($element); + $element['#value'] = $value_callback($element, FALSE, $form_state); } // Final catch. If we haven't set a value yet, use the explicit default value. // Avoid image buttons (which come with garbage value), so we only get value -- GitLab