fix typo and remove duplicate macro