Would be nice to have a more meaningful variable name here, such as $is_submenu_accessed, to indicate what the condition is for.