while trying to debug taxonomy ticker problem with not displaying terms in the admin i found that the problem really is with the core taxonomy.
please read my post and solution at the following link and implement the fix: http://drupal.org/node/117702
please implement this fix as i dont know how to submit patches yet.
thank you.
| Comment | File | Size | Author |
|---|---|---|---|
| #2 | taxonomy.module_38.patch | 827 bytes | RobRoy |
| #1 | drupal-taxonomy.module.patch.txt | 520 bytes | zonker |
Comments
Comment #1
zonker commentedAgreed - this is a really annoying problem with a very simple fix. I found the same problem in 4.7 and came up with much the same fix (before finding this issue node).
The issue is that taxonomy_form_all only returns categories which have two or more terms in them. This is clearly incorrect behaviour, and the function should return categories which also have just a single term.
Patch for 4.7 attached. The exact equivalent applies to 5.x.
Nick
Comment #2
RobRoy commentedDon't even need that in there. See http://us2.php.net/manual/en/language.types.boolean.php#language.types.b.... An empty array results in false and since taxonomy_get_tree always returns an array we can just do this. (We could do if ($tree = taxonomy_get_tree($vid))) but I like this better.
Comment #3
litwol commentedi do not agree with you. by some freak of nature bug $tree might become a positive number that will result this conditional statememt to evaluate to true. this is a potential door to another bug.
Comment #4
RobRoy commentedNo. Heh, have you looked at taxonomy_get_tree()? It will always be an array. Trust me.
Comment #5
drummAlready fixed by http://drupal.org/node/107822.