Index: modules/system/system.install
===================================================================
RCS file: /cvs/drupal/drupal/modules/system/system.install,v
retrieving revision 1.346
diff -u -r1.346 system.install
--- modules/system/system.install	21 Jun 2009 05:18:44 -0000	1.346
+++ modules/system/system.install	22 Jun 2009 05:58:31 -0000
@@ -3565,14 +3565,20 @@
  */
 function system_update_7028() {
   $ret = array();
-  db_rename_table($ret, 'term_data', 'taxonomy_term_data');
-  db_rename_table($ret, 'term_hierarchy', 'taxonomy_term_hierarchy');
-  db_rename_table($ret, 'term_node', 'taxonomy_term_node');
-  db_rename_table($ret, 'term_relation', 'taxonomy_term_relation');
-  db_rename_table($ret, 'term_synonym', 'taxonomy_term_synonym');
-  db_rename_table($ret, 'vocabulary', 'taxonomy_vocabulary');
-  db_rename_table($ret, 'vocabulary_node_types', 'taxonomy_vocabulary_node_type');
-
+  $tables = array(
+    'term_data' => 'taxonomy_term_data',
+    'term_hierarchy' => 'taxonomy_term_hierarchy',
+    'term_node' => 'taxonomy_term_node',
+    'term_relation' => 'taxonomy_term_relation',
+    'term_synonym' => 'taxonomy_term_synonym',
+    'vocabulary' => 'taxonomy_vocabulary',
+    'vocabulary_node_types' => 'taxonomy_vocabulary_node_type'
+  );
+  foreach ($tables as $from => $to) {
+    if (db_table_exists($from)) {
+      db_rename_table($ret, $from, $to);
+    }
+  }
   return $ret;
 }
 
