build: update to yarn v4 (#48994)
* build: update to yarn v4 (cherry picked from commit 6adec744f3411240a63fd194a319b510872eca93) * chore: fixup types after yarn v4 migration * chore: update nan yarn.lock patch * build: automatically install git for dugite
This commit is contained in:
parent
aeb5af803f
commit
b2e73d28e2
48 changed files with 18341 additions and 11314 deletions
|
|
@ -119,7 +119,10 @@ export function fetchWithSession (input: RequestInfo, init: (RequestInit & {bypa
|
|||
p.reject(err);
|
||||
});
|
||||
|
||||
if (!req.body?.pipeTo(Writable.toWeb(r as unknown as Writable)).then(() => r.end())) { r.end(); }
|
||||
// pipeTo expects a WritableStream<Uint8Array>. Node.js' Writable.toWeb returns WritableStream<any>,
|
||||
// which causes a TS structural mismatch.
|
||||
const writable = Writable.toWeb(r as unknown as Writable) as unknown as WritableStream<Uint8Array>;
|
||||
if (!req.body?.pipeTo(writable).then(() => r.end())) { r.end(); }
|
||||
|
||||
return p.promise;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue