diff options
author | Matthew Miller <matthew@millerti.me> | 2022-11-06 09:07:56 -0800 |
---|---|---|
committer | Matthew Miller <matthew@millerti.me> | 2022-11-06 09:07:56 -0800 |
commit | 7fe7aca361c7432038c542d6e1c1c0357aeaeb79 (patch) | |
tree | dd830569e16e65bd295d08d3dda91ff5f587f2fc /packages/server/src/helpers/decodeAttestationObject.ts | |
parent | 1b35937b2c97ac8fe1410ca624b40def8a927020 (diff) |
Get consistent on use of decodeCborFirst
Diffstat (limited to 'packages/server/src/helpers/decodeAttestationObject.ts')
-rw-r--r-- | packages/server/src/helpers/decodeAttestationObject.ts | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/packages/server/src/helpers/decodeAttestationObject.ts b/packages/server/src/helpers/decodeAttestationObject.ts index 5385106..bab6ced 100644 --- a/packages/server/src/helpers/decodeAttestationObject.ts +++ b/packages/server/src/helpers/decodeAttestationObject.ts @@ -1,4 +1,4 @@ -import cbor from 'cbor'; +import { decodeCborFirst } from './decodeCbor'; /** * Convert an AttestationObject buffer to a proper object @@ -6,7 +6,7 @@ import cbor from 'cbor'; * @param base64AttestationObject Attestation Object buffer */ export function decodeAttestationObject(attestationObject: Buffer): AttestationObject { - const toCBOR: AttestationObject = cbor.decodeAllSync(attestationObject)[0]; + const toCBOR: AttestationObject = decodeCborFirst(attestationObject); return toCBOR; } |