minor refactoring 2