more refactorings