Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
shell.js: Handle if location object does not exist
When compiling with the options introduced in [this comment](#13190 (comment)), the `ENVIRONMENT_IS_WORKER` value is set to `true`. In Deno, the value of `self.location` is `undefined` when the `deno run` command is executed without the `--location` CLI argument. In the scenario of creating the Deno library, it is difficult to tell the library user to input the `--location` CLI argument, so I modified it to handle fallback at this level.
- Loading branch information