summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGábor Hojtsy2011-07-27 08:02:12 (GMT)
committer Gábor Hojtsy2011-07-27 08:02:12 (GMT)
commit95df3c3959a371fa47c9b72858326fd59f0633a3 (patch)
tree61cf40183e1cac1b7b1aa2a7e5935a31dfcd10d5
parent6fac4ab83f84e7f2bb3141ff078602688fbad25b (diff)
Issue #188947 by lyricnz: date_validate() takes a form element, not a whole form, correct the variable name to clean this up
-rw-r--r--includes/form.inc6
1 files changed, 3 insertions, 3 deletions
diff --git a/includes/form.inc b/includes/form.inc
index a443b9b..54cda83 100644
--- a/includes/form.inc
+++ b/includes/form.inc
@@ -1720,9 +1720,9 @@ function expand_date($element) {
/**
* Validates the date type to stop dates like February 30, 2006.
*/
-function date_validate($form) {
- if (!checkdate($form['#value']['month'], $form['#value']['day'], $form['#value']['year'])) {
- form_error($form, t('The specified date is invalid.'));
+function date_validate($element) {
+ if (!checkdate($element['#value']['month'], $element['#value']['day'], $element['#value']['year'])) {
+ form_error($element, t('The specified date is invalid.'));
}
}