[wp-trac] [WordPress Trac] #16521: Inconsistent return values in get_category_link and get_tag_link

WordPress Trac wp-trac at lists.automattic.com
Thu Feb 10 21:37:29 UTC 2011


#16521: Inconsistent return values in get_category_link and get_tag_link
------------------------------------+-----------------------
 Reporter:  nacin                   |       Owner:
     Type:  defect (bug)            |      Status:  reopened
 Priority:  normal                  |   Milestone:  3.1
Component:  General                 |     Version:
 Severity:  critical                |  Resolution:
 Keywords:  has-patch dev-feedback  |
------------------------------------+-----------------------

Comment (by ryan):

 If the arg is not an object, it is cast to int. This disallows slugs, but
 that seems the only sane path.  get_term_link() is returned to what is was
 before since the phpdoc for says WP_Error can be returned and there are
 places in the code that explicitly check for a WP_Error return.

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/16521#comment:11>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list