refactor persists