From c4b02c121301af3cea351ec6f267aa3b1099bdd5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?G=C3=A1bor=20Hojtsy?= Date: Mon, 10 Sep 2007 08:06:59 +0000 Subject: #174343 by Shiny: move JOIN condition to ON clause in forum_nodeapi, so our SQL is standards compatible --- modules/forum/forum.module | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'modules/forum') diff --git a/modules/forum/forum.module b/modules/forum/forum.module index a061011f1..01c631c8e 100644 --- a/modules/forum/forum.module +++ b/modules/forum/forum.module @@ -251,7 +251,7 @@ function forum_nodeapi(&$node, $op, $teaser, $page) { $node->tid = $term_id; } } - $old_tid = db_result(db_query_range("SELECT t.tid FROM {term_node} t INNER JOIN {node} n WHERE t.vid = n.vid AND n.nid = %d ORDER BY t.vid DESC", $node->nid, 0, 1)); + $old_tid = db_result(db_query_range("SELECT t.tid FROM {term_node} t INNER JOIN {node} n ON t.vid = n.vid WHERE n.nid = %d ORDER BY t.vid DESC", $node->nid, 0, 1)); if ($old_tid) { if (($node->tid != $old_tid) && $node->shadow) { // A shadow copy needs to be created. Retain new term and add old term. -- cgit v1.2.3