Merge pull request #5703 from BlueWallet/fix-delete-faulty-wallets

FIX: unable to delete faulty wallet (rel #5661)
This commit is contained in:
GLaDOS 2023-09-28 19:18:45 +01:00 committed by GitHub
commit ab9ac9a8a2
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -506,7 +506,16 @@ const WalletDetails = () => {
return (
<>
<Text style={[styles.textLabel1, stylesHook.textLabel1]}>{loc.wallets.details_address.toLowerCase()}</Text>
<Text style={[styles.textValue, stylesHook.textValue]}>{wallet.getAddress()}</Text>
<Text style={[styles.textValue, stylesHook.textValue]}>
{(() => {
// gracefully handling faulty wallets, so at least user has an option to delete the wallet
try {
return wallet.getAddress();
} catch (error) {
return error.message;
}
})()}
</Text>
</>
);
}