From 3ce46fdfb0a4bc6226d43171ae9171b192ba4ad2 Mon Sep 17 00:00:00 2001 From: Andrew Steele Date: Fri, 2 Aug 2019 06:51:40 -0700 Subject: [PATCH] Fix issue with ledger not returning nano prefix --- package.json | 4 ++-- src/app/services/wallet.service.ts | 5 +++-- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/package.json b/package.json index 6ebd42f1..5e87dc1f 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "NanoVault", - "version": "1.2.0", + "version": "1.2.1", "license": "MIT", "description": "Wallet for interacting with Nano", "author": "Andrew Steele", @@ -93,7 +93,7 @@ }, "build": { "appId": "com.electron.nanovault", - "buildVersion": "1.2.0", + "buildVersion": "1.2.1", "productName": "NanoVault", "copyright": "Copyright © 2019 Andrew Steele", "directories": { diff --git a/src/app/services/wallet.service.ts b/src/app/services/wallet.service.ts index a873e20c..4e5f86cf 100644 --- a/src/app/services/wallet.service.ts +++ b/src/app/services/wallet.service.ts @@ -446,10 +446,11 @@ export class WalletService { const account: any = await this.ledgerService.getLedgerAccount(index); const accountID = account.address; - const addressBookName = this.addressBook.getAccountName(accountID); + const nanoAccountID = accountID.replace('xrb_', 'nano_'); + const addressBookName = this.addressBook.getAccountName(nanoAccountID); const newAccount: WalletAccount = { - id: accountID, + id: nanoAccountID, frontier: null, secret: null, keyPair: null,