From 585aa50e6a2d7d8f67f8116c207a342c47728dfb Mon Sep 17 00:00:00 2001 From: Angie Byron Date: Wed, 28 Jan 2009 01:09:58 +0000 Subject: #346156 by stBorchert, swentel, and catch: Fix deletion of terms (with tests). --- modules/taxonomy/taxonomy.module | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'modules/taxonomy/taxonomy.module') diff --git a/modules/taxonomy/taxonomy.module b/modules/taxonomy/taxonomy.module index 4e25c3bd8..b28e0a306 100644 --- a/modules/taxonomy/taxonomy.module +++ b/modules/taxonomy/taxonomy.module @@ -765,8 +765,8 @@ function taxonomy_get_parents($tid, $key = 'tid') { */ function taxonomy_get_parents_all($tid) { $parents = array(); - if ($tid) { - $parents[] = taxonomy_term_load($tid); + if ($term = taxonomy_term_load($tid)) { + $parents[] = $term; $n = 0; while ($parent = taxonomy_get_parents($parents[$n]->tid)) { $parents = array_merge($parents, $parent); -- cgit v1.2.3