some refactor
total refactoring