Fix active menu detection