try to check for webassembly in a different place
This commit is contained in:
parent
d0946d3ab5
commit
d100473542
|
@ -12,10 +12,6 @@ import init, {
|
||||||
set_room_name,
|
set_room_name,
|
||||||
} from './pkg/pixsy.js';
|
} from './pkg/pixsy.js';
|
||||||
|
|
||||||
if (typeof WebAssembly !== "object") {
|
|
||||||
window.location = "./old/"
|
|
||||||
}
|
|
||||||
|
|
||||||
// stolen from https://ourcodeworld.com/articles/read/189/how-to-create-a-file-and-generate-a-download-with-javascript-in-the-browser-without-a-server
|
// stolen from https://ourcodeworld.com/articles/read/189/how-to-create-a-file-and-generate-a-download-with-javascript-in-the-browser-without-a-server
|
||||||
function download(filename, text) {
|
function download(filename, text) {
|
||||||
let element = document.createElement('a');
|
let element = document.createElement('a');
|
||||||
|
@ -60,6 +56,10 @@ function readFile(input, callback, type = "text") {
|
||||||
}
|
}
|
||||||
|
|
||||||
async function run() {
|
async function run() {
|
||||||
|
if (typeof WebAssembly !== "object") {
|
||||||
|
window.location = "http://tinybird.info/image-to-bitsy/old/"
|
||||||
|
}
|
||||||
|
|
||||||
await init();
|
await init();
|
||||||
|
|
||||||
const buttonAddImage = el("add");
|
const buttonAddImage = el("add");
|
||||||
|
|
Loading…
Reference in New Issue