Refactoring WIP 3