Index: delete_orphaned_terms/delete_orphaned_terms.module
===================================================================
RCS file: /cvs/drupal/contributions/modules/delete_orphaned_terms/delete_orphaned_terms.module,v
retrieving revision 1.2.2.10
diff -u -r1.2.2.10 delete_orphaned_terms.module
--- delete_orphaned_terms/delete_orphaned_terms.module	4 Mar 2010 21:54:38 -0000	1.2.2.10
+++ delete_orphaned_terms/delete_orphaned_terms.module	14 Aug 2010 20:38:02 -0000
@@ -67,7 +67,7 @@
   $vocabularies = taxonomy_get_vocabularies();
   foreach ($vocabularies as $vocabulary) {
     $vocab_names[$vocabulary->vid] = $vocabulary->name;
-    $count = count(taxonomy_get_tree($vocabulary->vid));
+    $count = db_result(db_query('SELECT count(tid) FROM {term_data} WHERE vid=%d', $vocabulary->vid));
     if ($verbose) {
       $vocab_names[$vocabulary->vid] .= ' ('. $count . ' terms)';
     }
