diff options
author | Matthew Miller <matthew@millerti.me> | 2021-02-02 14:27:52 -0800 |
---|---|---|
committer | Matthew Miller <matthew@millerti.me> | 2021-02-02 14:27:52 -0800 |
commit | 0ae478ab58b0826daba32ed9d854cb3f3fd3cba7 (patch) | |
tree | 108bfbde7e2dcec955567c066397362ad336f610 /packages/browser/src | |
parent | bb7989b1f3ce451a78bff17827787ddfb058b944 (diff) |
Convert user handle to Buffer on client
Diffstat (limited to 'packages/browser/src')
-rw-r--r-- | packages/browser/src/methods/startAttestation.ts | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/packages/browser/src/methods/startAttestation.ts b/packages/browser/src/methods/startAttestation.ts index 0b2235d..9594bb9 100644 --- a/packages/browser/src/methods/startAttestation.ts +++ b/packages/browser/src/methods/startAttestation.ts @@ -4,7 +4,6 @@ import { AttestationCredentialJSON, } from '@simplewebauthn/typescript-types'; -import toUint8Array from '../helpers/toUint8Array'; import bufferToBase64URLString from '../helpers/bufferToBase64URLString'; import base64URLStringToBuffer from '../helpers/base64URLStringToBuffer'; import supportsWebauthn from '../helpers/supportsWebauthn'; @@ -28,7 +27,7 @@ export default async function startAttestation( challenge: base64URLStringToBuffer(creationOptionsJSON.challenge), user: { ...creationOptionsJSON.user, - id: toUint8Array(creationOptionsJSON.user.id), + id: base64URLStringToBuffer(creationOptionsJSON.user.id), }, excludeCredentials: creationOptionsJSON.excludeCredentials.map(toPublicKeyCredentialDescriptor), }; |