Skip to content

Commit

Permalink
web: Rename variable for fallback WASM module name
Browse files Browse the repository at this point in the history
  • Loading branch information
danielhjacobs committed Jan 14, 2025
1 parent 23ed90e commit 7412f57
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions web/packages/core/src/load-ruffle.ts
Original file line number Diff line number Diff line change
Expand Up @@ -63,12 +63,12 @@ async function fetchRuffle(
ZipWriter,
} = await (extensionsSupported
? import("../dist/ruffle_web-wasm_extensions")
: // @ts-expect-error TypeScript compiler is trying to do the import
import("../dist/%WASM_MVP%"));
: // @ts-expect-error TS2307 TypeScript compiler is trying to do the import.
import("../dist/%FALLBACK_WASM%"));
let response;
const wasmUrl = extensionsSupported
? new URL("../dist/ruffle_web-wasm_extensions_bg.wasm", import.meta.url)
: new URL("../dist/%WASM_MVP%_bg.wasm", import.meta.url);
: new URL("../dist/%FALLBACK_WASM%_bg.wasm", import.meta.url);
const wasmResponse = await fetch(wasmUrl);
// The Pale Moon browser lacks full support for ReadableStream.
// However, ReadableStream itself is defined.
Expand Down
6 changes: 3 additions & 3 deletions web/packages/core/tools/set_version.ts
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ if (process.env["ENABLE_VERSION_SEAL"] === "true") {
}
}

const wasmMvpName =
const fallbackWasmName =
process.env["BUILD_WASM_MVP"] === "true"
? "ruffle_web"
: "ruffle_web-wasm_extensions";
Expand All @@ -77,15 +77,15 @@ const options = {
/%VERSION_CHANNEL%/g,
/%BUILD_DATE%/g,
/%COMMIT_HASH%/g,
/%WASM_MVP%/g,
/%FALLBACK_WASM%/g,
],
to: [
versionNumber,
versionName,
versionChannel,
buildDate,
commitHash,
wasmMvpName,
fallbackWasmName,
],
};

Expand Down

0 comments on commit 7412f57

Please sign in to comment.