some code refactorings
some code refactorings