diff --git a/squeal-postgresql/src/Squeal/PostgreSQL/Session.hs b/squeal-postgresql/src/Squeal/PostgreSQL/Session.hs index 9adf2324..051e9097 100644 --- a/squeal-postgresql/src/Squeal/PostgreSQL/Session.hs +++ b/squeal-postgresql/src/Squeal/PostgreSQL/Session.hs @@ -214,9 +214,9 @@ instance (Monad m, db0 ~ db1) return = pure (>>=) = flip pqBind -instance (Monad m, db0 ~ db1) +instance (MonadFail m, db0 ~ db1) => Fail.MonadFail (PQ db0 db1 m) where - fail = Fail.fail + fail = lift . Fail.fail instance db0 ~ db1 => MFunctor (PQ db0 db1) where hoist f (PQ pq) = PQ (f . pq)