diff options
author | Dries Buytaert <dries@buytaert.net> | 2004-07-06 07:38:35 +0000 |
---|---|---|
committer | Dries Buytaert <dries@buytaert.net> | 2004-07-06 07:38:35 +0000 |
commit | 4e9ef33896bc0798f766e684e1c57783a2d700a7 (patch) | |
tree | c6327e39522984e7067d1a3b24ce8807696bf14e /modules/tracker.module | |
parent | 7bb88809b7eb4bf8cb410f6234bfe1ba43e553a2 (diff) | |
download | brdo-4e9ef33896bc0798f766e684e1c57783a2d700a7.tar.gz brdo-4e9ef33896bc0798f766e684e1c57783a2d700a7.tar.bz2 |
- Patch #9031 by Ber: if the comment module is not available comment_num_all()
should not be called.
Diffstat (limited to 'modules/tracker.module')
-rw-r--r-- | modules/tracker.module | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/modules/tracker.module b/modules/tracker.module index 36791ecd6..9b68752ae 100644 --- a/modules/tracker.module +++ b/modules/tracker.module @@ -52,12 +52,14 @@ function tracker_page($uid = 0) { while ($node = db_fetch_object($result)) { // Determine the number of comments: - if ($all = comment_num_all($node->nid)) { - $comments = $all; - - if ($new = comment_num_new($node->nid)) { - $comments .= '<br />'; - $comments .= l(t('%num new', array('%num' => $new)), "node/$node->nid", NULL, NULL, 'new'); + if (module_exist('comment')) { + if ($all = comment_num_all($node->nid)) { + $comments = $all; + + if ($new = comment_num_new($node->nid)) { + $comments .= '<br />'; + $comments .= l(t('%num new', array('%num' => $new)), "node/$node->nid", NULL, NULL, 'new'); + } } } else { |