diff options
author | Dries Buytaert <dries@buytaert.net> | 2006-12-01 16:50:36 +0000 |
---|---|---|
committer | Dries Buytaert <dries@buytaert.net> | 2006-12-01 16:50:36 +0000 |
commit | 46a6e08ceaa2fee6d0fbae3435036f91289d5a3e (patch) | |
tree | cb1a7186a21c0236748ed9cac08482c53d243b01 /modules/comment/comment.module | |
parent | 9460c93033ed5b394cbf95f766d6f120559544fc (diff) | |
download | brdo-46a6e08ceaa2fee6d0fbae3435036f91289d5a3e.tar.gz brdo-46a6e08ceaa2fee6d0fbae3435036f91289d5a3e.tar.bz2 |
- Patch #51314 by kjartan, eafarris, et al: hide the last comment block if there are no comments.
Diffstat (limited to 'modules/comment/comment.module')
-rw-r--r-- | modules/comment/comment.module | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/modules/comment/comment.module b/modules/comment/comment.module index ee29f3a89..41abf8595 100644 --- a/modules/comment/comment.module +++ b/modules/comment/comment.module @@ -178,7 +178,9 @@ function theme_comment_block() { while ($comment = db_fetch_object($result)) { $items[] = l($comment->subject, 'node/'. $comment->nid, NULL, NULL, 'comment-'. $comment->cid) .'<br />'. t('@time ago', array('@time' => format_interval(time() - $comment->timestamp))); } - return theme('item_list', $items); + if ($items) { + return theme('item_list', $items); + } } /** |