diff --git a/src/app/features/ledger/utils/generic-ledger-utils.ts b/src/app/features/ledger/utils/generic-ledger-utils.ts index 270add765a3..f7ca22a0b70 100644 --- a/src/app/features/ledger/utils/generic-ledger-utils.ts +++ b/src/app/features/ledger/utils/generic-ledger-utils.ts @@ -64,23 +64,23 @@ export function prepareLedgerDeviceForAppFn Promise>(co type TransportInstance = Awaited>; // Reference: https://github.com/LedgerHQ/ledger-live/blob/v22.0.1/src/hw/quitApp.ts -export async function quitApp(transport: TransportInstance): Promise { +async function quitApp(transport: TransportInstance): Promise { await transport.send(0xb0, 0xa7, 0x00, 0x00); } // Reference: https://github.com/LedgerHQ/ledger-live/blob/v22.0.1/src/hw/openApp.ts -export async function openApp(transport: TransportInstance, name: string): Promise { +async function openApp(transport: TransportInstance, name: string): Promise { await transport.send(0xe0, 0xd8, 0x00, 0x00, Buffer.from(name, 'ascii')); } -export async function getAppAndVersion() { +async function getAppAndVersion() { const tmpTransport = await TransportWebUSB.create(); const tmpBitcoinApp = new BitcoinApp(tmpTransport); const appAndVersion = await tmpBitcoinApp.getAppAndVersion(); return appAndVersion; } -export async function quitAppOnDevice() { +async function quitAppOnDevice() { const tmpTransport = await TransportWebUSB.create(); await quitApp(tmpTransport); // for some reason sending quit app buffer to ledger will close the connection afterwards.