From 1370071e6816363380913a7bb37fff34e3cad7c9 Mon Sep 17 00:00:00 2001 From: Adam Fraser Date: Fri, 22 Dec 2023 10:26:20 -0800 Subject: [PATCH] Allow HandlerAspect.customAuthProvidingZIO To Fail With User Specified Response (#2493) * relax type constraint * update documentation --------- Co-authored-by: John A. De Goes --- zio-http/src/main/scala/zio/http/HandlerAspect.scala | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/zio-http/src/main/scala/zio/http/HandlerAspect.scala b/zio-http/src/main/scala/zio/http/HandlerAspect.scala index 787b764431..c4c4f7d196 100644 --- a/zio-http/src/main/scala/zio/http/HandlerAspect.scala +++ b/zio-http/src/main/scala/zio/http/HandlerAspect.scala @@ -364,7 +364,7 @@ private[http] trait HandlerAspects extends zio.http.internal.HeaderModifier[Hand * handlers. */ def customAuthProvidingZIO[Env, Context]( - provide: Request => ZIO[Env, Nothing, Option[Context]], + provide: Request => ZIO[Env, Response, Option[Context]], responseHeaders: Headers = Headers.empty, responseStatus: Status = Status.Unauthorized, ): HandlerAspect[Env, Context] =