Skip to content
This repository has been archived by the owner on May 10, 2024. It is now read-only.

Commit

Permalink
No Bug: Fix for bad access crash causing flakey test (#8684)
Browse files Browse the repository at this point in the history
Fix for bad access crash when accessing non-thread safe dict from background thread. Resolves flakey `SelectAccountTokenStoreTests` unit test test.
  • Loading branch information
StephenHeaps authored Jan 19, 2024
1 parent bd215d9 commit 9314fc8
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -324,7 +324,7 @@ class SelectAccountTokenStore: ObservableObject, WalletObserverStore {
return nil
}
var price: String?
if let tokenPrice = pricesForTokensCache[token.assetRatioId.lowercased()],
if let tokenPrice = pricesCache[token.assetRatioId.lowercased()],
balance > 0 {
price = currencyFormatter.string(from: NSNumber(value: (Double(tokenPrice) ?? 0) * balance))
}
Expand Down

0 comments on commit 9314fc8

Please sign in to comment.