do minor refactoring