[wp-trac] [WordPress Trac] #23627: Allow plugins to short-circuit wp_nav_menu, good for performance

WordPress Trac noreply at wordpress.org
Wed Feb 5 15:47:47 UTC 2014


#23627: Allow plugins to short-circuit wp_nav_menu, good for performance
-------------------------+-----------------------
 Reporter:  kasparsd     |       Owner:
     Type:  enhancement  |      Status:  new
 Priority:  normal       |   Milestone:  3.9
Component:  Menus        |     Version:  3.5.1
 Severity:  normal       |  Resolution:
 Keywords:  has-patch    |     Focuses:  template
-------------------------+-----------------------

Comment (by nacin):

 A few other things I'd suggest:
  * Returning false or `''` should cause the function to short-circuit.
 Only returning null should allow execution to continue. (While I prefer
 this, core has historically reversed false and null. Either works.)
  * The filter will [http://make.wordpress.org/core/handbook/inline-
 documentation-standards/php-documentation-standards/ need documentation].

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


More information about the wp-trac mailing list