swap nesting order of ErrorT and ReaderT monads