diff --git a/packages/snap/post-process.js b/packages/snap/post-process.js index 17fb8b2..5bdd2b5 100644 --- a/packages/snap/post-process.js +++ b/packages/snap/post-process.js @@ -10,42 +10,12 @@ let bundleString = fs.readFileSync(bundlePath, 'utf8'); bundleString = 'var self = window;\n'.concat(bundleString); // Remove 'use asm' tokens; they cause pointless console warnings -bundleString = bundleString.replaceAll( - "c6.process", - "{}.process", -); -bundleString = bundleString.replaceAll( - "c6.WeakMap", - "undefined", -); -bundleString = bundleString.replaceAll( - "c6.WeakMap", - "globalThis.WeakMap", -); -bundleString = bundleString.replaceAll( - "c6.BigInt", - "globalThis.BigInt", -); -bundleString = bundleString.replaceAll( - "c6.RangeError", - "globalThis.RangeError", -); + bundleString = bundleString.replaceAll( "a=c6", - "a={}", -); -bundleString = bundleString.replaceAll( - "c6.caml_fs_tmp", - "undefined", -); -bundleString = bundleString.replaceAll( - "c6.caml_create_file", - "undefined", -); -bundleString = bundleString.replaceAll( - "c6.toplevelReloc", - "undefined", + "a=globalThis", ); + bundleString = bundleString.replaceAll( ";undefined=cxl;undefined=[]", "", diff --git a/packages/snap/snap.manifest.json b/packages/snap/snap.manifest.json index 492f3ec..c6e4d0a 100644 --- a/packages/snap/snap.manifest.json +++ b/packages/snap/snap.manifest.json @@ -7,7 +7,7 @@ "url": "https://github.com/Chainsafe/minasnap.git" }, "source": { - "shasum": "+e/XYL24x3utSQaa1hG4zfp5kGp8zND25O0YNmvzNd0=", + "shasum": "uucaRo7BnJvq/PcgqWfDTQCzPcXgPqoNhyG/5PyjZXA=", "location": { "npm": { "filePath": "dist/bundle.js",