[wp-trac] [WordPress Trac] #21943: register_post_type() expect array but should object as well

WordPress Trac wp-trac at lists.automattic.com
Thu Sep 20 18:35:24 UTC 2012


#21943: register_post_type() expect array but should object as well
-------------------------+----------------------
 Reporter:  thomask      |       Owner:
     Type:  enhancement  |      Status:  closed
 Priority:  normal       |   Milestone:
Component:  Post Types   |     Version:  trunk
 Severity:  normal       |  Resolution:  wontfix
 Keywords:               |
-------------------------+----------------------
Changes (by scribu):

 * status:  new => closed
 * resolution:   => wontfix
 * milestone:  Awaiting Review =>


Comment:

 Yeah; due to the pass-by-reference thing, register_post_type() would have
 to create a new instance anyway, to avoid weird side-effects.

 Besides, I don't think cloning post types should be something that the API
 encourages.

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


More information about the wp-trac mailing list