simplify menu parsing