typo
minor refactoring