I think we officially have too many copies of this logic.  Filing an issue to refactor it out into a helper function.