From da774e124b206a1826f0b81191167db50b38af8d Mon Sep 17 00:00:00 2001 From: Sergey Biryukov Date: Mon, 7 Feb 2022 14:19:31 +0000 Subject: [PATCH] Coding Standards: Rename `$r` variable to `$args` for clarity in `walk_page_tree()`. Follow-up to [9830], [32617], [45667], [52684]. See #54728. git-svn-id: https://develop.svn.wordpress.org/trunk@52685 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/post-template.php | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/wp-includes/post-template.php b/src/wp-includes/post-template.php index dcf272051d..1c8b3ba600 100644 --- a/src/wp-includes/post-template.php +++ b/src/wp-includes/post-template.php @@ -1521,26 +1521,26 @@ function wp_page_menu( $args = array() ) { * @param array $pages * @param int $depth * @param int $current_page - * @param array $r + * @param array $args * @return string */ -function walk_page_tree( $pages, $depth, $current_page, $r ) { - if ( empty( $r['walker'] ) ) { +function walk_page_tree( $pages, $depth, $current_page, $args ) { + if ( empty( $args['walker'] ) ) { $walker = new Walker_Page; } else { /** * @var Walker $walker */ - $walker = $r['walker']; + $walker = $args['walker']; } foreach ( (array) $pages as $page ) { if ( $page->post_parent ) { - $r['pages_with_children'][ $page->post_parent ] = true; + $args['pages_with_children'][ $page->post_parent ] = true; } } - return $walker->walk( $pages, $depth, $r, $current_page ); + return $walker->walk( $pages, $depth, $args, $current_page ); } /**