[wp-trac] [WordPress Trac] #14162: Introduce WP_Term class

WordPress Trac noreply at wordpress.org
Fri Sep 11 10:18:42 UTC 2015


#14162: Introduce WP_Term class
--------------------------------------+---------------------------
 Reporter:  scribu                    |       Owner:  boonebgorges
     Type:  enhancement               |      Status:  assigned
 Priority:  normal                    |   Milestone:  4.4
Component:  Taxonomy                  |     Version:
 Severity:  normal                    |  Resolution:
 Keywords:  needs-patch dev-feedback  |     Focuses:
--------------------------------------+---------------------------

Comment (by flixos90):

 Based on attachment:14162.2.patch I created the above patch with the
 following adjustments:

 * if no taxonomy is defined in `get_term()`, make sure the filters still
 receive a valid taxonomy name
 * made `$taxonomy` argument optional for the functions
   * `get_term_by()`
   * `get_term_field()`
   * `get_term_to_edit()`
   * `term_is_ancestor_of()`
   * `sanitize_term()`
 * in the above functions, if a taxonomy name is not specified, but
 required (like for a filter), the taxonomy of the term is used

--
Ticket URL: <https://core.trac.wordpress.org/ticket/14162#comment:25>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list