diff --git a/package.json b/package.json index 374f3fe..1ad4dfd 100644 --- a/package.json +++ b/package.json @@ -9,8 +9,8 @@ "clean": "rimraf ./dist", "build": "npm run clean && rollup -c && tsc --project ./src/tsconfig.json", "build:prod": "npm run clean && rollup -c --environment NODE_ENV:production && tsc --project ./src/tsconfig.json", - "deploy": "npm run build && gcloud app deploy dev.yaml --project=try-webauthn", - "deploy:prod": "npm run build:prod && gcloud app deploy app.yaml --project=try-webauthn", + "deploy": "gcloud app deploy dev.yaml --project=try-webauthn", + "deploy:prod": "gcloud app deploy app.yaml --project=try-webauthn", "gcp-build": "npm run build:prod", "dev": "NODE_ENV=localhost node dist/server.mjs", "emulator": "firebase emulators:start --only firestore,auth --project try-webauthn --import=./.data --export-on-exit", diff --git a/src/libs/webauthn.mts b/src/libs/webauthn.mts index 4e079af..7a09c8c 100644 --- a/src/libs/webauthn.mts +++ b/src/libs/webauthn.mts @@ -74,9 +74,8 @@ export const getOrigin = ( const octArray = hashes[i].split(':').map((h) => parseInt(h, 16), ); - const uint8Array = new Uint8Array(octArray.length); // @ts-ignore - const androidHash = isoBase64URL.fromBuffer(uint8Array); + const androidHash = isoBase64URL.fromBuffer(octArray); origin = `android:apk-key-hash:${androidHash}`; break; }