refactor ALL the things