fixing typo and unit test