[wp-trac] [WordPress Trac] #38765: Argument in registered_taxonomy hook is lost.

WordPress Trac noreply at wordpress.org
Wed Nov 16 18:01:43 UTC 2016


#38765: Argument in registered_taxonomy hook is lost.
--------------------------+-------------------------
 Reporter:  Toro_Unit     |       Owner:  swissspidy
     Type:  defect (bug)  |      Status:  assigned
 Priority:  normal        |   Milestone:  4.7
Component:  Taxonomy      |     Version:  trunk
 Severity:  normal        |  Resolution:
 Keywords:  has-patch     |     Focuses:  docs
--------------------------+-------------------------

Comment (by swissspidy):

 For the `registered_post_type` hook, we could easily do this because
 `$args` was already an object there. That's not the case for
 `registered_taxonomy`. What we could do:

 1) Replace `$args` with `WP_Taxonomy`, add to dev-note
 2) Cast the taxonomy object to an array
 3) Implement the `ArrayAccess` interface in `WP_Taxonomy`

 @boonebgorges As you have reviewed #36224 previously, what's your take on
 this?

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


More information about the wp-trac mailing list