refactor interactive menu method