some changes
big bang of refactoring