Skip to content

Commit

Permalink
Restored old behavior of sinkBody, see brendanhay#466
Browse files Browse the repository at this point in the history
  • Loading branch information
reactormonk committed May 30, 2018
1 parent 9750d3d commit 9cf94c5
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions amazonka/src/Network/AWS/Internal/Body.hs
Expand Up @@ -26,8 +26,8 @@ getFileSize :: MonadIO m => FilePath -> m Integer
getFileSize path = liftIO (withBinaryFile path ReadMode hFileSize)

-- | Connect a 'Sink' to a response stream.
sinkBody :: MonadIO m => RsBody -> ConduitM ByteString Void (ResourceT IO) a -> m a
sinkBody (RsBody body) sink = liftIO $ runConduitRes $ body .| sink
sinkBody :: (MonadResource m, MonadIO m) => RsBody -> ConduitM ByteString Void (ResourceT IO) a -> m a
sinkBody (RsBody body) sink = liftResourceT $ runConduit $ body .| sink

-- | Construct a 'HashedBody' from a 'FilePath', calculating the 'SHA256' hash
-- and file size.
Expand Down

0 comments on commit 9cf94c5

Please sign in to comment.