Skip to content

Commit ddb2f5c

Browse files
authored
feat: Mark Ledger accounts missing shielded account as outdated (#2099)
1 parent fd4b75f commit ddb2f5c

File tree

2 files changed

+16
-1
lines changed

2 files changed

+16
-1
lines changed

apps/extension/src/App/Accounts/ParentAccounts.tsx

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,20 @@ export const ParentAccounts = (): JSX.Element => {
5353
}
5454
});
5555

56+
// We check whether a Ledger parent has an associated shielded account
57+
allAccounts
58+
.filter(
59+
(account) => !account.parentId && account.type === AccountType.Ledger
60+
)
61+
.forEach(({ id }) => {
62+
const shieldedAccount = allAccounts.find(
63+
({ parentId }) => parentId === id
64+
);
65+
if (!shieldedAccount) {
66+
allParentAccounts[id]["outdated"] = true;
67+
}
68+
});
69+
5670
const accounts = Object.values(allParentAccounts);
5771

5872
useEffect(() => {

apps/extension/src/App/Accounts/UpdateRequired.tsx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,8 @@ export const UpdateRequired = (): JSX.Element => {
7171
</li>
7272
<li>Delete the marked account from 
the keychain</li>
7373
<li>
74-
Re-Import the account using your seed phrase / private key
74+
Re-Import the account using your seed phrase / private key /
75+
Ledger HW wallet
7576
</li>
7677
</ol>
7778
</Stack>

0 commit comments

Comments
 (0)