Starting to refactor...