mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-12-23 01:39:44 +01:00
Fix undefined provider menu item
This commit is contained in:
parent
822face7a3
commit
1e46d858e9
@ -258,7 +258,7 @@ App.prototype.renderNetworkDropdown = function () {
|
||||
activeNetworkRender: props.provider.rpcTarget,
|
||||
}),
|
||||
|
||||
this.renderCustomOption(props.provider.rpcTarget),
|
||||
this.renderCustomOption(props.provider),
|
||||
|
||||
h(DropMenuItem, {
|
||||
label: 'Custom RPC',
|
||||
@ -480,7 +480,10 @@ App.prototype.toggleMetamaskActive = function () {
|
||||
}
|
||||
}
|
||||
|
||||
App.prototype.renderCustomOption = function (rpcTarget) {
|
||||
App.prototype.renderCustomOption = function (provider) {
|
||||
const { rpcTarget, type } = provider
|
||||
if (type !== 'rpc') return null
|
||||
|
||||
switch (rpcTarget) {
|
||||
|
||||
case 'http://localhost:8545':
|
||||
|
Loading…
Reference in New Issue
Block a user