fix typo and missing definition