From 3ee6f6bbc578ecd2f9d0b581bfa9b6e1abac40dd Mon Sep 17 00:00:00 2001 From: Angie Byron Date: Sat, 4 Dec 2010 01:47:00 +0000 Subject: #903392 by jhodgdon, rayasa: Fixed 'Add new comment' text appears in search result snippet --- modules/comment/comment.module | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'modules/comment') diff --git a/modules/comment/comment.module b/modules/comment/comment.module index 4bb8db7f3..2eebcfb7b 100644 --- a/modules/comment/comment.module +++ b/modules/comment/comment.module @@ -650,11 +650,11 @@ function comment_node_view($node, $view_mode) { } } } - elseif ($view_mode != 'search_index') { + elseif ($view_mode != 'search_index' && $view_mode != 'search_result') { // Node in other view modes: add a "post comment" link if the user is // allowed to post comments and if this node is allowing new comments. // But we don't want this link if we're building the node for search - // indexing. + // indexing or constructing a search result excerpt. if ($node->comment == COMMENT_NODE_OPEN) { if (user_access('post comments')) { $links['comment-add'] = array( -- cgit v1.2.3