summaryrefslogtreecommitdiff
path: root/modules/forum
diff options
context:
space:
mode:
authorDries Buytaert <dries@buytaert.net>2007-05-07 17:02:54 +0000
committerDries Buytaert <dries@buytaert.net>2007-05-07 17:02:54 +0000
commitc32e17e3f24ed0f096045571ffbb56e672197c67 (patch)
treeb1662f40b66c0836a60807d6588e7d2b235965cd /modules/forum
parent1e6c37aeac88919d16e04e6013927569aa73e1e8 (diff)
downloadbrdo-c32e17e3f24ed0f096045571ffbb56e672197c67.tar.gz
brdo-c32e17e3f24ed0f096045571ffbb56e672197c67.tar.bz2
- Patch #141665 by ChrisKennedy: E_ALL fixes.
Diffstat (limited to 'modules/forum')
-rw-r--r--modules/forum/forum.module8
1 files changed, 4 insertions, 4 deletions
diff --git a/modules/forum/forum.module b/modules/forum/forum.module
index cce09b291..fad2a05e4 100644
--- a/modules/forum/forum.module
+++ b/modules/forum/forum.module
@@ -350,7 +350,7 @@ function forum_view(&$node, $teaser = FALSE, $page = FALSE) {
*/
function forum_submit(&$node) {
// Make sure all fields are set properly:
- $node->icon = $node->icon ? $node->icon : '';
+ $node->icon = !empty($node->icon) ? $node->icon : '';
if ($node->taxonomy) {
// Get the forum terms from the (cached) tree
@@ -838,7 +838,7 @@ function forum_get_topics($tid, $sortby, $forum_per_page) {
$sql_count = db_rewrite_sql("SELECT COUNT(n.nid) FROM {node} n INNER JOIN {term_node} r ON n.nid = r.nid AND r.tid = %d WHERE n.status = 1 AND n.type = 'forum'");
$result = pager_query($sql, $forum_per_page, 0, $sql_count, $tid);
-
+ $topics = array();
while ($topic = db_fetch_object($result)) {
if ($user->uid) {
// folder is new if topic is new or there are new comments since last visit
@@ -1038,7 +1038,7 @@ function theme_forum_list($forums, $parents, $tid) {
*/
function theme_forum_topic_list($tid, $topics, $sortby, $forum_per_page) {
global $forum_topic_list_header;
-
+ $rows = array();
if ($topics) {
foreach ($topics as $topic) {
@@ -1139,7 +1139,7 @@ function theme_forum_topic_navigation($node) {
// Word break (a is an inline element)
$output .= ' ';
}
- if ($next) {
+ if (!empty($next)) {
$output .= l($next->title . t(' ›'), 'node/'. $next->nid, array('class' => 'topic-next', 'title' => t('Go to next forum topic')));
}