- Patch #73351 by Kris, Goba et al: only display comment link in RSS, if applicable.

5.x
Dries Buytaert 2006-07-13 12:29:15 +00:00
parent 254b8bbaac
commit e4e416d1f7
1 changed files with 6 additions and 1 deletions

View File

@ -328,7 +328,12 @@ function comment_nodeapi(&$node, $op, $arg = 0) {
return format_plural($comments, '1 comment', '%count comments');
case 'rss item':
return array(array('key' => 'comments', 'value' => url('node/'. $node->nid, NULL, 'comment', TRUE)));
if ($node->comment != COMMENT_NODE_DISABLED) {
return array(array('key' => 'comments', 'value' => url('node/'. $node->nid, NULL, 'comment', TRUE)));
}
else {
return array();
}
}
}