[wp-trac] [WordPress Trac] #33413: most PHP classes should be in their own file

WordPress Trac noreply at wordpress.org
Tue Aug 18 23:14:05 UTC 2015


#33413: most PHP classes should be in their own file
----------------------------+--------------------
 Reporter:  wonderboymusic  |       Owner:
     Type:  enhancement     |      Status:  new
 Priority:  normal          |   Milestone:  4.4
Component:  General         |     Version:  trunk
 Severity:  normal          |  Resolution:
 Keywords:  dev-feedback    |     Focuses:
----------------------------+--------------------

Comment (by pento):

 I'd probably add a block to include the classes in their original location
 if they're undefined, in case people are manually including individual
 files.

 ie, in `query.php`:

 {{{
 if ( ! class_exists( 'WP_Query' ) ) {
     require( ABSPATH . WPINC . '/class-wp-query.php' );
 }
 }}}

 The massive churn is not my favourite thing in the world, especially for
 some of the more complex classes that regularly need SVN log archeology to
 find out why a part works like it does.

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


More information about the wp-trac mailing list