2021-01-06 15:31:16 -05:00
|
|
|
self.onmessage = async () => {
|
|
|
|
const hrtime = await Deno.permissions.query({ name: "hrtime" });
|
|
|
|
const net = await Deno.permissions.query({ name: "net" });
|
2021-08-06 17:28:10 -04:00
|
|
|
const ffi = await Deno.permissions.query({ name: "ffi" });
|
2021-01-06 15:31:16 -05:00
|
|
|
const read = await Deno.permissions.query({ name: "read" });
|
|
|
|
const run = await Deno.permissions.query({ name: "run" });
|
|
|
|
const write = await Deno.permissions.query({ name: "write" });
|
|
|
|
self.postMessage(
|
|
|
|
hrtime.state === "denied" &&
|
|
|
|
net.state === "denied" &&
|
2021-08-06 17:28:10 -04:00
|
|
|
ffi.state === "denied" &&
|
2021-01-06 15:31:16 -05:00
|
|
|
read.state === "denied" &&
|
|
|
|
run.state === "denied" &&
|
|
|
|
write.state === "denied",
|
|
|
|
);
|
|
|
|
self.close();
|
|
|
|
};
|