diff options
author | Bartek IwaĆczuk <biwanczuk@gmail.com> | 2020-09-16 22:22:43 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-09-16 22:22:43 +0200 |
commit | 6c4da0e429eb47dae6a220c5576a39f137615bb8 (patch) | |
tree | a8715428caea00105acc9a10fcd0f356085d3fa7 /cli/rt/11_resources.js | |
parent | 104aebdfb5d01f7482bacef6d58c2ce16da44334 (diff) |
refactor: remove dispatch_json.js from cli/rt and cli/tsc (#7521)
Instead use Deno.core.jsonOpSync and Deno.core.jsonOpAsync
Diffstat (limited to 'cli/rt/11_resources.js')
-rw-r--r-- | cli/rt/11_resources.js | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/cli/rt/11_resources.js b/cli/rt/11_resources.js index 247e033cc..9a1595b78 100644 --- a/cli/rt/11_resources.js +++ b/cli/rt/11_resources.js @@ -1,10 +1,10 @@ // Copyright 2018-2020 the Deno authors. All rights reserved. MIT license. ((window) => { - const sendSync = window.__bootstrap.dispatchJson.sendSync; + const core = window.Deno.core; function resources() { - const res = sendSync("op_resources"); + const res = core.jsonOpSync("op_resources"); const resources = {}; for (const resourceTuple of res) { resources[resourceTuple[0]] = resourceTuple[1]; @@ -13,7 +13,7 @@ } function close(rid) { - sendSync("op_close", { rid }); + core.jsonOpSync("op_close", { rid }); } window.__bootstrap.resources = { |