Refactor to helper methods in the model.