refactor client.pull