fix solana node update logic

This commit is contained in:
julian 2024-11-26 10:30:49 -06:00
parent 31fe9a538b
commit 7d047e8d47

View file

@ -357,16 +357,19 @@ class SolanaWallet extends Bip39Wallet<Solana> {
@override @override
Future<void> updateNode() async { Future<void> updateNode() async {
_solNode = getCurrentNode(); _solNode = NodeService(secureStorageInterface: secureStorageInterface)
.getPrimaryNodeFor(currency: info.coin) ??
info.coin.defaultNode;
await refresh(); await refresh();
} }
@override @override
NodeModel getCurrentNode() { NodeModel getCurrentNode() {
return _solNode ?? _solNode ??= NodeService(secureStorageInterface: secureStorageInterface)
NodeService(secureStorageInterface: secureStorageInterface)
.getPrimaryNodeFor(currency: info.coin) ?? .getPrimaryNodeFor(currency: info.coin) ??
info.coin.defaultNode; info.coin.defaultNode;
return _solNode!;
} }
@override @override