refactor expand into utility