Skip to content

Commit

Permalink
Merge pull request #1683 from alexcrichton/no-modules-lenient
Browse files Browse the repository at this point in the history
Improve leniency of `--no-modules` output
  • Loading branch information
alexcrichton committed Jul 30, 2019
2 parents 68a1519 + 423bebb commit 78db35d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion crates/cli-support/src/js/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -502,7 +502,7 @@ impl<'a> Context<'a> {
let result;
const imports = {{}};
{imports_init}
if (module instanceof URL || typeof module === 'string' || module instanceof Request) {{
if ((typeof URL === 'function' && module instanceof URL) || typeof module === 'string' || (typeof Request === 'function' && module instanceof Request)) {{
{init_memory2}
const response = fetch(module);
if (typeof WebAssembly.instantiateStreaming === 'function') {{
Expand Down

0 comments on commit 78db35d

Please sign in to comment.