Docs: Clarify the name and description of some parameters in the Walker class.

Follow-up to [53323].
See #54729.


git-svn-id: https://develop.svn.wordpress.org/trunk@53324 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Jb Audras 2022-05-01 21:45:56 +00:00
parent 4cfee4c129
commit 50add1e31b

View File

@ -426,16 +426,16 @@ class Walker {
*
* @since 2.7.0
*
* @param object $e
* @param array $children_elements
* @param object $element The top level element.
* @param array $children_elements The children elements.
*/
public function unset_children( $e, &$children_elements ) {
if ( ! $e || ! $children_elements ) {
public function unset_children( $element, &$children_elements ) {
if ( ! $element || ! $children_elements ) {
return;
}
$id_field = $this->db_fields['id'];
$id = $e->$id_field;
$id = $element->$id_field;
if ( ! empty( $children_elements[ $id ] ) && is_array( $children_elements[ $id ] ) ) {
foreach ( (array) $children_elements[ $id ] as $child ) {