@samitouri / QOSami-HFS / commits / 823c122f

avoid using chunked mode making http requests

Massimo Melina committed Oct 8, 2023 at 16:05 UTC 823c122f6d5dd4c1aaa37a48e3dacdccdb3f1371
1 file changed +1 -3
src/util-http.ts
+1 -3
@@ -36,9 +36,7 @@ export function httpStream(url: string, { body, ...options }:XRequestOptions ={}
36 }).on('error', e => {
37 reject((req as any).res || e)
38 })
39 - if (body)
40 - req.write(body)
41 - req.end()
39 + req.end(body)
40 })
41 }
42