mirror of
git://develop.git.wordpress.org/
synced 2025-02-06 23:50:43 +01:00
Modify `wp_nav_menu_remove_menu_item_has_children_class()` to account for changes to the `nav_menu_css_class` filter since it's introduction. The `$args` and `$depth` parameters were added after the filter's introduction so this protects against fatal errors in custom walkers applying the filter in a legacy format. Without the `$args` or `$depth` parameters, `wp_nav_menu_remove_menu_item_has_children_class()` no longer attempts to remove the `menu-item-has-children` from the lowest level menu items as these are required to determine the current branch the walker is walking. Follow up to [54999]. Props dd32, azaozz, peterwilsoncc. See #56926, #28620. git-svn-id: https://develop.svn.wordpress.org/trunk@55005 602fd350-edb4-49c9-b593-d223f7449a82