[wp-trac] [WordPress Trac] #30109: Inconsistent args type passed to Walker's start_el() method

WordPress Trac noreply at wordpress.org
Sun Oct 26 17:34:40 UTC 2014


#30109: Inconsistent args type passed to Walker's start_el() method
--------------------------+-----------------------------
 Reporter:  howardtw      |      Owner:
     Type:  defect (bug)  |     Status:  new
 Priority:  normal        |  Milestone:  Awaiting Review
Component:  General       |    Version:  trunk
 Severity:  normal        |   Keywords:
  Focuses:                |
--------------------------+-----------------------------
 According to the doc [1], all args should be an array


 {{{
 start_lvl( &$output, $depth = 0, $args = array() )
 end_lvl( &$output, $depth = 0, $args = array() )
 start_el( &$output, $object, $depth = 0, $args = array(),
 $current_object_id = 0 )

 }}}

 But in wp-admin/includes/nav-menu.php, object is being passed instead of
 array


 {{{

   28     /**
   29      * @see Walker::start_el()
   30      * @since 3.0.0
   31      *
   32      * @param string $output Passed by reference. Used to append
 additional content.
   33      * @param object $item Menu item data object.
   34      * @param int $depth Depth of menu item. Used for padding.
   35      * @param object $args
   36      */
   37     function start_el(&$output, $item, $depth, $args) {



 }}}






 [1] http://codex.wordpress.org/Class_Reference/Walker

--
Ticket URL: <https://core.trac.wordpress.org/ticket/30109>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list