Moving everything to a stateT