summaryrefslogtreecommitdiff
path: root/modules/comment/comment.module
diff options
context:
space:
mode:
authorDries Buytaert <dries@buytaert.net>2007-03-26 00:35:59 +0000
committerDries Buytaert <dries@buytaert.net>2007-03-26 00:35:59 +0000
commiteb6b848de609469d313a1d48b6b7f8a559c9e289 (patch)
tree034aa0a102aeb6f4c4f4eaf78d5c2062257350cb /modules/comment/comment.module
parent2e0bb6e939e54c5cc8fe03e583d07b358cffb0c4 (diff)
downloadbrdo-eb6b848de609469d313a1d48b6b7f8a559c9e289.tar.gz
brdo-eb6b848de609469d313a1d48b6b7f8a559c9e289.tar.bz2
- Patch #110888 by Eaton: unify hook _alter()
Diffstat (limited to 'modules/comment/comment.module')
-rw-r--r--modules/comment/comment.module9
1 files changed, 3 insertions, 6 deletions
diff --git a/modules/comment/comment.module b/modules/comment/comment.module
index 499db5a0e..8f060c300 100644
--- a/modules/comment/comment.module
+++ b/modules/comment/comment.module
@@ -374,7 +374,7 @@ function comment_link($type, $node = NULL, $teaser = FALSE) {
return $links;
}
-function comment_form_alter($form_id, &$form) {
+function comment_form_alter($form, $form_id) {
if ($form_id == 'node_type_form' && isset($form['identity']['type'])) {
$form['workflow']['comment'] = array(
'#type' => 'radios',
@@ -403,6 +403,7 @@ function comment_form_alter($form_id, &$form) {
);
}
}
+ return $form;
}
/**
@@ -963,11 +964,7 @@ function comment_render($node, $cid = 0) {
if ($comment = db_fetch_object($result)) {
$comment->name = $comment->uid ? $comment->registered_name : $comment->name;
$links = module_invoke_all('link', 'comment', $comment, 1);
-
- foreach (module_implements('link_alter') as $module) {
- $function = $module .'_link_alter';
- $function($node, $links);
- }
+ drupal_alter('link', $links, $node);
$output .= theme('comment_view', $comment, $links);
}