Refactor greg