Skip to:
Content

BuddyPress.org

Changeset 12497


Ignore:
Timestamp:
11/13/2019 02:25:01 AM (5 months ago)
Author:
johnjamesjacoby
Message:

Admin: add ..$args to Nav Walker to match signature in WordPress 5.3.

This commit is a quick fix for errors being triggered on WordPress.org.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/bp-core/classes/class-bp-walker-nav-menu.php

    r11363 r12497  
    4848     *
    4949     * @since 1.7.0
    50      *
     50     * @since 6.0.0 Formalized the existing `...$args` parameter by adding it
     51     *              to the function signature to match WordPress 5.3.
    5152     * @see Walker::walk()
    5253     *
    5354     * @param array $elements  See {@link Walker::walk()}.
    5455     * @param int   $max_depth See {@link Walker::walk()}.
     56     * @param mixed ...$args   Optional additional arguments.
    5557     * @return string See {@link Walker::walk()}.
    5658     */
    57     public function walk( $elements, $max_depth ) {
    58         $args   = array_slice( func_get_args(), 2 );
     59    public function walk( $elements, $max_depth, ...$args ) {
    5960        $output = '';
    6061
Note: See TracChangeset for help on using the changeset viewer.