Moves some more logic to helper methods