[wp-trac] [WordPress Trac] #32366: wp_count_comments() is hardcoded into /wp-admin/menu.php and queries all comments every single page load within the admin area, regardless of if edt_posts is removed from top menu or not

WordPress Trac noreply at wordpress.org
Fri Nov 27 03:35:13 UTC 2015


#32366: wp_count_comments() is hardcoded into /wp-admin/menu.php and queries all
comments every single page load within the admin area, regardless of if
edt_posts is removed from top menu or not
---------------------------+------------------------------------------
 Reporter:  justindocanto  |       Owner:
     Type:  defect (bug)   |      Status:  reopened
 Priority:  normal         |   Milestone:  Future Release
Component:  Comments       |     Version:  4.2
 Severity:  normal         |  Resolution:
 Keywords:  has-patch      |     Focuses:  administration, performance
---------------------------+------------------------------------------
Changes (by chacha102):

 * keywords:  needs-patch => has-patch


Comment:

 Given that it is in the base of a file that you can't stop from loading, I
 think a filter is going to be the best approach. Plus, the menu item is
 still accessible for administrators. Just the comment count is removed.

 This does not, however, do anything to allow you to temporarily cache the
 value or anything else. Just remove the comment count.

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


More information about the wp-trac mailing list