support deno fetch
This commit is contained in:
parent
775cb0a426
commit
560bd67655
@ -17,7 +17,14 @@ import {rootCertificates} from "node:tls";
|
||||
import {timerel} from "timerel";
|
||||
|
||||
const {fromUrl} = hostedGitInfo;
|
||||
const fetch = fetchEnhanced(nodeFetch, {undici: false});
|
||||
|
||||
let fetch;
|
||||
if (globalThis.Deno && globalThis.fetch) {
|
||||
fetch = globalThis.fetch;
|
||||
} else {
|
||||
fetch = fetchEnhanced(nodeFetch, {undici: false});
|
||||
}
|
||||
|
||||
const MAX_SOCKETS = 96;
|
||||
const sep = "\0";
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user