and one more refactoring