Fix state fetch handler so it remembers previous state.