mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-11-29 07:16:36 +01:00
9847179f54
We now set the network status to "unknown" rather than "unavailable" when the network ID is invalid. This better reflects what we know when this happens, and it makes the network controller better aligned with the core network controller. This was accomplished by using a regular error for the network ID assertion rather than using `assert` directly. `assert` would throw an error with a `code` property, which resutled in us treating it like an RPC error. This isn't tested, but it was found in the course of porting unit tests from core to extension. It will be covered by these tests, which will be added in the next PR. This change should have no functional impact because we treat these two network statuses as equivalent. The distinction between unknown and unavailable is useful only for debugging. |
||
---|---|---|
.. | ||
ens | ||
network | ||
permissions | ||
transactions | ||
alert.js | ||
app-state.js | ||
app-state.test.js | ||
backup.js | ||
backup.test.js | ||
cached-balances.js | ||
cached-balances.test.js | ||
decrypt-message.test.ts | ||
decrypt-message.ts | ||
detect-tokens.js | ||
detect-tokens.test.js | ||
encryption-public-key.test.ts | ||
encryption-public-key.ts | ||
incoming-transactions.js | ||
incoming-transactions.test.js | ||
metametrics.js | ||
metametrics.test.js | ||
onboarding.js | ||
preferences.js | ||
preferences.test.js | ||
swaps.js | ||
swaps.test.js |