Commit 80b9a0f
authored
Ensure
In debugging a long-standing issue where SelectedNetworkController
sometimes requests invalid network client IDs from NetworkController,
one bug was discovered in NetworkController. Namely, when a network is
removed, its data is removed from `networkConfigurationsByChainId`, but
not `networksMetadata`. This commit fixes `removeNetwork` to do this,
and ensures that when the controller is initialized, if
`networksMetadata` contains invalid network client IDs, they are
removed.networksMetadata never references old network client IDs (#7047)1 parent 2a2dc96 commit 80b9a0f
File tree
5 files changed
+258
-87
lines changed- packages
- gas-fee-controller/src
- network-controller
- src
- tests
5 files changed
+258
-87
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
63 | 63 | | |
64 | 64 | | |
65 | 65 | | |
66 | | - | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
67 | 76 | | |
68 | 77 | | |
69 | 78 | | |
| |||
86 | 95 | | |
87 | 96 | | |
88 | 97 | | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
89 | 102 | | |
90 | 103 | | |
91 | 104 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
13 | 13 | | |
14 | 14 | | |
15 | 15 | | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
16 | 22 | | |
17 | 23 | | |
18 | 24 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1082 | 1082 | | |
1083 | 1083 | | |
1084 | 1084 | | |
1085 | | - | |
| 1085 | + | |
1086 | 1086 | | |
1087 | 1087 | | |
| 1088 | + | |
| 1089 | + | |
| 1090 | + | |
| 1091 | + | |
| 1092 | + | |
1088 | 1093 | | |
1089 | 1094 | | |
1090 | | - | |
| 1095 | + | |
1091 | 1096 | | |
1092 | 1097 | | |
1093 | 1098 | | |
| |||
1101 | 1106 | | |
1102 | 1107 | | |
1103 | 1108 | | |
| 1109 | + | |
| 1110 | + | |
| 1111 | + | |
| 1112 | + | |
| 1113 | + | |
| 1114 | + | |
| 1115 | + | |
| 1116 | + | |
| 1117 | + | |
| 1118 | + | |
| 1119 | + | |
| 1120 | + | |
1104 | 1121 | | |
1105 | 1122 | | |
1106 | 1123 | | |
| |||
2401 | 2418 | | |
2402 | 2419 | | |
2403 | 2420 | | |
| 2421 | + | |
| 2422 | + | |
| 2423 | + | |
| 2424 | + | |
2404 | 2425 | | |
2405 | 2426 | | |
2406 | 2427 | | |
| |||
0 commit comments