refactor fetch