[wp-trac] [WordPress Trac] #11737: PHP Notice in get_cat_name()

WordPress Trac wp-trac at lists.automattic.com
Wed Jan 6 07:49:02 UTC 2010

#11737: PHP Notice in get_cat_name()
 Reporter:  miqrogroove       |       Owner:  westi
     Type:  defect (bug)      |      Status:  new  
 Priority:  normal            |   Milestone:  3.0  
Component:  Warnings/Notices  |     Version:       
 Severity:  normal            |    Keywords:       

Comment(by nacin):

 Turns out it is only WP_Error when the taxonomy doesn't exist.
 get_category() will return such a WP_Error via get_term(), but if the
 taxonomy exists but the term doesn't, then a null value is returned.

 For get_cat_name(), I think you should be expecting either a name or

 The larger fix I mentioned above doesn't seem to be needed here -- all we
 need to do is patch get_cat_name(), apparently.

Ticket URL: <http://core.trac.wordpress.org/ticket/11737#comment:3>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software

More information about the wp-trac mailing list