1-st refactor done