proposed refactor