mirror of
https://github.com/denoland/deno.git
synced 2024-11-25 15:29:32 -05:00
fix(ext/fetch): don't use global Deno object
Don't use `Deno.core`, it's not present in embedders that don't expose the Deno global object.
This commit is contained in:
parent
eea6f578fc
commit
6ddabb7427
1 changed files with 3 additions and 3 deletions
|
@ -523,15 +523,15 @@
|
|||
while (true) {
|
||||
const { value: chunk, done } = await reader.read();
|
||||
if (done) break;
|
||||
Deno.core.wasmStreamingFeed(rid, "bytes", chunk);
|
||||
core.wasmStreamingFeed(rid, "bytes", chunk);
|
||||
}
|
||||
}
|
||||
|
||||
// 2.7.
|
||||
Deno.core.wasmStreamingFeed(rid, "finish");
|
||||
core.wasmStreamingFeed(rid, "finish");
|
||||
} catch (err) {
|
||||
// 2.8 and 3
|
||||
Deno.core.wasmStreamingFeed(rid, "abort", err);
|
||||
core.wasmStreamingFeed(rid, "abort", err);
|
||||
}
|
||||
})();
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue