summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDries Buytaert <dries@buytaert.net>2009-07-07 13:53:25 +0000
committerDries Buytaert <dries@buytaert.net>2009-07-07 13:53:25 +0000
commit2f3955503e45eab5bbe6e6bafd99fed9803ade2a (patch)
treedbb7bb1f7aee5ba4b3b56c8f005d5979e16d77cc
parenta4411976fd67b01b02063f3c7a757df4e300761a (diff)
downloadbrdo-2f3955503e45eab5bbe6e6bafd99fed9803ade2a.tar.gz
brdo-2f3955503e45eab5bbe6e6bafd99fed9803ade2a.tar.bz2
- Patch #512492 by DamZ: removed hook_validate, a relic of old times. Form API FTW!
-rw-r--r--modules/comment/comment.api.php17
-rw-r--r--modules/comment/comment.module3
2 files changed, 0 insertions, 20 deletions
diff --git a/modules/comment/comment.api.php b/modules/comment/comment.api.php
index 2f1624fb5..92f247a86 100644
--- a/modules/comment/comment.api.php
+++ b/modules/comment/comment.api.php
@@ -23,23 +23,6 @@ function hook_comment_insert($comment) {
}
/**
- * The user has just finished editing the comment and is trying to
- * preview or submit it. This hook can be used to check or
- * even modify the comment. Errors should be set with form_set_error().
- *
- * @param $form_values
- * Passes in an array of form values submitted by the user.
- * @return
- * Nothing.
- */
-function hook_comment_validate(&$form_values) {
- // if the subject is the same as the comment.
- if ($form_values['subject'] == $form_values['comment']) {
- form_set_error('comment', t('you should write more text than in the subject'));
- }
-}
-
-/**
* The comment is being updated.
*
* @param $comment
diff --git a/modules/comment/comment.module b/modules/comment/comment.module
index 2aacca3d7..8c8a7b55e 100644
--- a/modules/comment/comment.module
+++ b/modules/comment/comment.module
@@ -1747,9 +1747,6 @@ function comment_form_validate($form, &$form_state) {
}
}
- // Invoke other validation handlers.
- module_invoke_all('comment_validate', $form_state['values']);
-
if (isset($form_state['values']['date'])) {
if (strtotime($form_state['values']['date']) === FALSE) {
form_set_error('date', t('You have to specify a valid date.'));