From 97368980d83eaa4d5618b2a0181d8c87eba9c901 Mon Sep 17 00:00:00 2001
From: Brandon Bergren <bdragon@rtk0.net>
Date: Fri, 14 Jan 2011 00:32:20 +0000
Subject: [PATCH] Update table names for taxonomy tables.

---
 gmap_taxonomy.module | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/gmap_taxonomy.module b/gmap_taxonomy.module
index 59786bd..ca57970 100644
--- a/gmap_taxonomy.module
+++ b/gmap_taxonomy.module
@@ -190,10 +190,10 @@ function gmap_taxonomy_nodeapi(&$node, $op, $a3 = NULL, $a4 = NULL) {
 /**
  * Reassign markers associated with a term that's going away.
  */
-function gmap_taxonomy_reassign_marker($tid, $table = 'term_node') {
+function gmap_taxonomy_reassign_marker($tid, $table = 'taxonomy_term_node') {
   $result = db_query('SELECT vid FROM {:table} WHERE tid = :tid', array(':table' => db_escape_table($table), ':tid' => $tid));
   while ($node = db_fetch_object($result)) {
-    $markers = db_query('SELECT t.tid, gt.marker FROM {term_node} r INNER JOIN {gmap_taxonomy_term} gt ON r.tid = gt.tid INNER JOIN {term_data} t ON r.tid = t.tid INNER JOIN {vocabulary} v ON t.vid = v.vid WHERE r.vid = :vid ORDER BY v.weight DESC, t.weight DESC, t.name DESC', array(':vid' => $node->vid));
+    $markers = db_query('SELECT t.tid, gt.marker FROM {taxonomy_term_node} r INNER JOIN {gmap_taxonomy_term} gt ON r.tid = gt.tid INNER JOIN {taxonomy_term_data} t ON r.tid = t.tid INNER JOIN {taxonomy_vocabulary} v ON t.vid = v.vid WHERE r.vid = :vid ORDER BY v.weight DESC, t.weight DESC, t.name DESC', array(':vid' => $node->vid));
     if ($marker = db_fetch_object($markers)) {
       // Fallback found.
       db_update('gmap_taxonomy_node')
-- 
GitLab