summaryrefslogtreecommitdiff
path: root/cli/tests/if_main.ts
diff options
context:
space:
mode:
authorBartek IwaƄczuk <biwanczuk@gmail.com>2020-05-01 20:15:28 +0200
committerGitHub <noreply@github.com>2020-05-01 20:15:28 +0200
commit6661e7e287aa595eccdc8d49940c40953b1f69bc (patch)
tree4e936d8aa3ee3acbc7c012072d160a5793401c93 /cli/tests/if_main.ts
parent5d3c49082ffa96fc97af1e7bf637c930dd9cdf66 (diff)
BREAKING: remove window.location and self.location (#5034)
This commit removes "location" global available on "window", "globalThis" and "self".
Diffstat (limited to 'cli/tests/if_main.ts')
-rw-r--r--cli/tests/if_main.ts3
1 files changed, 1 insertions, 2 deletions
diff --git a/cli/tests/if_main.ts b/cli/tests/if_main.ts
index b47066b2d..4dcfecea0 100644
--- a/cli/tests/if_main.ts
+++ b/cli/tests/if_main.ts
@@ -1,7 +1,6 @@
-if (window.location.toString() == import.meta.url) {
+if (import.meta.main) {
console.log("main");
} else {
console.log("import.meta.url", import.meta.url);
- console.log("window.location", window.location.toString());
throw Error("not main");
}