Craig's refactor