[wp-trac] [WordPress Trac] #11458: Remove unnecessary $posts_per_page global in admin.php

WordPress Trac wp-trac at lists.automattic.com
Wed Dec 16 15:47:22 UTC 2009


#11458: Remove unnecessary $posts_per_page global in admin.php
----------------------------+-----------------------------------------------
 Reporter:  nacin           |       Owner:           
     Type:  defect (bug)    |      Status:  new      
 Priority:  low             |   Milestone:  3.0      
Component:  Administration  |     Version:  2.9      
 Severity:  minor           |    Keywords:  has-patch
----------------------------+-----------------------------------------------
 First discussed in #11385.

 There is an orphaned {{{$posts_per_page = get_option('posts_per_page')}}}
 in the admin.php bootstrap. The variable is never used and appears to be
 an artifact that is left over from before the time of screen options.

 The posts_per_page option is the reading option for the number of posts to
 display per page in a theme.

 In the off-chance a plugin used this variable, it is overwritten in
 post.php anyway, and would provide incorrect values on any other page, as
 they have their own *_per_page user options. As of [12375] they also have
 a complete set of filters as well.

 If someone feels that broken back compat is necessary here, then we can
 wontfix.

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/11458>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list