[wp-trac] [WordPress Trac] #14761: unregister_post_type()

WordPress Trac noreply at wordpress.org
Thu Jan 7 15:46:10 UTC 2016


#14761: unregister_post_type()
-------------------------------------------------+-------------------------
 Reporter:  nacin                                |       Owner:
     Type:  enhancement                          |      Status:  assigned
 Priority:  normal                               |   Milestone:  4.5
Component:  Posts, Post Types                    |     Version:  2.9
 Severity:  normal                               |  Resolution:
 Keywords:  early has-patch has-unit-tests dev-  |     Focuses:
  feedback                                       |
-------------------------------------------------+-------------------------

Comment (by swissspidy):

 [attachment:14761.4.diff] is a refreshed patch with some more tests after
 feedback on #35227 and the other tickets related to this. Every bit of the
 function is now covered, so I'm certain that it works.

 The main thing that I'd love to hear some feedback on is making
 `$post_type_meta_caps` a global variable. Currently it's a static variable
 inside `_post_type_meta_capabilities()`, which means deleting meta caps is
 not possible.

 However, it's a fairly small change, so I'm not worried about it.

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


More information about the wp-trac mailing list