[wp-trac] [WordPress Trac] #15475: Proposed new function: wp_unset_object_terms

WordPress Trac wp-trac at lists.automattic.com
Sat Jul 9 09:07:26 UTC 2011


#15475: Proposed new function: wp_unset_object_terms
---------------------------------+-----------------------------
 Reporter:  simonwheatley        |       Owner:
     Type:  enhancement          |      Status:  new
 Priority:  normal               |   Milestone:  Future Release
Component:  Taxonomy             |     Version:
 Severity:  normal               |  Resolution:
 Keywords:  has-patch 3.3-early  |
---------------------------------+-----------------------------

Comment (by scribu):

 Coding standards:

 Avoid intermediary variables:

 {{{
 $tt_id = $term_info['term_taxonomy_id'];
 $tt_ids[] = $tt_id;
 }}}

 Add missing whitespace:

 {{{
 foreach ( (array) $terms as $term) {
 }}}

 {{{
 return new WP_Error('invalid_taxonomy', __('Invalid Taxonomy'));
 }}}

 {{{
 wp_update_term_count($delete_terms, $taxonomy);
 }}}

 etc.

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


More information about the wp-trac mailing list