Skip to content

Fix issue preventing topbar balance loading in development mode #5051

Ben requested to merge feat/hide-wallet-balance-head-5051 into master

Card: front#5051 (closed)

Front: front!1715 (merged)

Summary

If you have Rinkeby testnet set up locally (and I'd presume on sandbox) - the tokens you have are not on Uniswap and aren't on Rinkeby - meaning this section of code breaks when Uniswap doesn't come back with a derivedETH value.

This change simply returns a default value if the development flag is on. We could use client_network === 1 also, but I felt it is more verbose than is necessary.

Steps to test

Check you see the wallet topbar header

Estimated Regression Scope

Effects token price loaded from Uniswap

Impact on other platforms

Shouldn't have an impact except in the case of an issue with the logic, as mobile-only uses the production engine, which will return the mainnet values.

Edited by Ben

Merge request reports