[wp-trac] [WordPress Trac] #15000: add_meta_box() should accept array of post types

WordPress Trac noreply at wordpress.org
Sun Oct 5 13:00:43 UTC 2014


#15000: add_meta_box() should accept array of post types
-------------------------------------------------+-------------------------
 Reporter:  coffee2code                          |       Owner:
     Type:  enhancement                          |  madalin.ungureanu
 Priority:  normal                               |      Status:  assigned
Component:  Administration                       |   Milestone:  Awaiting
 Severity:  minor                                |  Review
 Keywords:  good-first-bug needs-unit-tests      |     Version:  3.0.1
  has-patch                                      |  Resolution:
                                                 |     Focuses:
-------------------------------------------------+-------------------------

Comment (by igmoweb):

 I've included a couple of tests more for this ticket based on @mordauk
 ones.

 I improved the test_remove_meta_box. When we use remove_meta_box, {{{
 $wp_meta_boxes['post']['advance']['default']['metabox1'] }}} was set to
 false but the key 'metabox1' was still present.

 I splitted the tests so now we have tests for add_meta_box when $screen
 cannot be an array and when $screen can be an array of post types.

 Sorry for the two EOLs in includesScreen.php as I started to make the
 tests there by mistake.

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


More information about the wp-trac mailing list