Support 'Duplex' streams in the existing 'Body' instance for streams (#187)
This commit is contained in:
parent
619c18e8a8
commit
c34b341a03
@ -82,7 +82,7 @@ instance bodyBuffer :: Body Buffer where
|
||||
-- | `Transfer-Encoding` header to indicate chunked data. To write the data, we
|
||||
-- | simply pipe the newtype-wrapped `Stream` to the response.
|
||||
instance bodyChunked ::
|
||||
TypeEquals (Stream r) (Readable ()) =>
|
||||
TypeEquals (Stream r) (Readable s) =>
|
||||
Body (Stream r) where
|
||||
defaultHeaders _ = pure $ header "Transfer-Encoding" "chunked"
|
||||
write body response = makeAff \done -> do
|
||||
|
Loading…
Reference in New Issue
Block a user