remove duplicated switch