_is_valid_nav_menu_item()WP 3.2.0

Determines whether a menu item is valid.

Internal function — this function is designed to be used by the kernel itself. It is not recommended to use this function in your code.

No Hooks.

Returns

bool. False if invalid, otherwise true.

Usage

_is_valid_nav_menu_item( $item );
$item(object) (required)
The menu item to check.

Changelog

Since 3.2.0 Introduced.

_is_valid_nav_menu_item() code WP 7.1

function _is_valid_nav_menu_item( $item ) {
	return empty( $item->_invalid );
}