[wp-trac] [WordPress Trac] #56926: Infinite loop in wp_nav_menu

WordPress Trac noreply at wordpress.org
Fri Dec 16 02:38:25 UTC 2022


#56926: Infinite loop in wp_nav_menu
--------------------------------------+-----------------------------
 Reporter:  david.binda               |       Owner:  hellofromTonya
     Type:  defect (bug)              |      Status:  closed
 Priority:  normal                    |   Milestone:  6.1.2
Component:  Menus                     |     Version:  6.1
 Severity:  normal                    |  Resolution:  fixed
 Keywords:  has-patch has-unit-tests  |     Focuses:
--------------------------------------+-----------------------------
Changes (by peterwilsoncc):

 * status:  assigned => closed
 * resolution:   => fixed


Comment:

 In [changeset:"54999" 54999]:
 {{{
 #!CommitTicketReference repository="" revision="54999"
 Menus: Prevent infinite loop in menus.

 This modifies how the `menu-item-has-children` class is removed from
 bottom level menu items. Instead of removing the class within
 `wp_nav_menu()` a filter is applied to the `nav_menu_css_class` hook to
 remove the class as required.

 Introduces `wp_nav_menu_remove_menu_item_has_children_class()` for
 removing the class.

 Reverts source code changes in [54478,54801], the tests are retained.

 Props davidbinda, SergeyBiryukov, mhkuu, JeffPaul, jmdodd, priethor,
 desrosj, hellofromTonya, azaozz, peterwilsoncc.
 Fixes #56926.
 See #28620.
 }}}

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


More information about the wp-trac mailing list