Skip to content

Commit

Permalink
fix cors proxy url
Browse files Browse the repository at this point in the history
  • Loading branch information
glitch003 committed Feb 14, 2024
1 parent 251482b commit c76cdb4
Showing 1 changed file with 4 additions and 7 deletions.
11 changes: 4 additions & 7 deletions packages/crypto/src/lib/crypto.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,7 @@ if (!globalThis.wasmExports) {

if (!globalThis.jestTesting) {
log(
`✅ [BLS SDK] wasmExports loaded. ${
Object.keys(exports).length
`✅ [BLS SDK] wasmExports loaded. ${Object.keys(exports).length
} functions available. Run 'wasmExports' in the console to see them.`
);
}
Expand All @@ -50,8 +49,7 @@ if (!globalThis.wasmECDSA) {

if (!globalThis.jestTesting) {
log(
`✅ [ECDSA SDK ${env}] wasmECDSA loaded. ${
Object.keys(wasmECDSA).length
`✅ [ECDSA SDK ${env}] wasmECDSA loaded. ${Object.keys(wasmECDSA).length
} functions available. Run 'wasmECDSA' in the console to see them.`
);
}
Expand All @@ -64,8 +62,7 @@ if (!globalThis.wasmSevSnpUtils) {

if (!globalThis.jestTesting) {
log(
`✅ [SEV SNP Utils SDK] wasmSevSnpUtils loaded. ${
Object.keys(exports).length
`✅ [SEV SNP Utils SDK] wasmSevSnpUtils loaded. ${Object.keys(exports).length
} functions available. Run 'wasmSevSnpUtils' in the console to see them.`
);
}
Expand Down Expand Up @@ -361,7 +358,7 @@ async function getAmdCert(url: string) {
// unfortunately, until AMD enables CORS, we have to use a proxy when in the browser
if (isBrowser()) {
// CORS proxy url
url = `https://shielded-earth-13917-10ba15245911.herokuapp.com/${url}`;
url = `https://cors.litgateway.com/${url}`;
}
const response = await fetch(url);
const arrayBuffer = await response.arrayBuffer();
Expand Down

0 comments on commit c76cdb4

Please sign in to comment.