From: Chris Duncan Date: Wed, 20 Aug 2025 16:18:11 +0000 (-0700) Subject: Fix return type for Ledger database backup. X-Git-Tag: v0.10.5~41^2~42 X-Git-Url: https://git.codecow.com/?a=commitdiff_plain;h=824b19c500646dd5176e01f18341e0bc1dd850bf;p=libnemo.git Fix return type for Ledger database backup. --- diff --git a/src/lib/wallet/backup.ts b/src/lib/wallet/backup.ts index c668aa3..bbabd7c 100644 --- a/src/lib/wallet/backup.ts +++ b/src/lib/wallet/backup.ts @@ -14,6 +14,9 @@ export async function _backup () { if (typeof id !== 'string') { throw new TypeError('Retrieved invalid ID', { cause: id }) } + if (type === 'Ledger') { + return { id, type, iv: new ArrayBuffer(0), salt: new ArrayBuffer(0), encrypted: new ArrayBuffer(0) } as const + } if (type !== 'BIP-44' && type !== 'BLAKE2b') { throw new TypeError('Retrieved invalid type', { cause: type }) }