on master help sign in
Merge pull request #7 from kazu-yamamoto/master
df84e29Michael Snoyman
warp/Network/Wai/Handler/Warp.hs+2−1
@@ -336,7 +336,8 @@ isChunked :: H.HttpVersion -> Bool
336isChunked = (==) H.http11
336isChunked = (==) H.http11
337
337
338hasBody :: H.Status -> Request -> Bool
338hasBody :: H.Status -> Request -> Bool
339−hasBody s req = s /= (H.Status 204 "") && requestMethod req /= "HEAD"
339+hasBody s req = s /= (H.Status 204 "") && s /= H.status304 &&
340+ H.statusCode s >= 200 && requestMethod req /= "HEAD"
340
341
341sendResponse :: T.Handle
342sendResponse :: T.Handle
342 -> Request -> Socket -> Response -> IO Bool
343 -> Request -> Socket -> Response -> IO Bool