switch from explicit state to ErrorT e State s