Opened 14 years ago
Closed 14 years ago
#15347 closed defect (bug) (fixed)
Confirm matching taxonomy in wp_list_categories()
Reported by: |
|
Owned by: | |
---|---|---|---|
Milestone: | 3.1 | Priority: | normal |
Severity: | normal | Version: | |
Component: | Taxonomy | Keywords: | |
Focuses: | Cc: |
Description
In wp_list_categories(), we detect the current category using the queried object. But, we don't check if the taxonomy of the queried object matches what we're displaying with wp_list_categories(). Clearly, the current category for purposes of listing categories needs to be the same taxonomy.
A get_term() call in Walker_Category will end up failing and we'll end up with warnings for trying to access non-existent properties. I traced that up the stack to here.
Also adding in is_tag() to the current term check because there's no reason why someone can't use wp_list_categories() for any taxonomy AFAIK.
Note: See
TracTickets for help on using
tickets.
(In [16250]) Confirm that the queried term object is of the requested taxonomy in wp_list_categories. fixes #15347.