WordPress.org

Make WordPress Core

Ticket #15808: 15808.diff

File 15808.diff, 716 bytes (added by scribu, 3 years ago)
  • wp-includes/nav-menu-template.php

     
    7373                $classes = empty( $item->classes ) ? array() : (array) $item->classes; 
    7474                $classes[] = 'menu-item-' . $item->ID; 
    7575 
    76                 $class_names = join( ' ', apply_filters( 'nav_menu_css_class', array_filter( $classes ), $item ) ); 
     76                $class_names = join( ' ', apply_filters( 'nav_menu_css_class', array_filter( $classes ), $item, $args ) ); 
    7777                $class_names = ' class="' . esc_attr( $class_names ) . '"'; 
    7878 
    7979                $id = apply_filters( 'nav_menu_item_id', 'menu-item-'. $item->ID, $item, $args );