small refactoring