c/menu_list: Removed duplicated code