refactor all the things!