Skip to content

Commit

Permalink
fix: chainid&symbol is optional for custom network
Browse files Browse the repository at this point in the history
Signed-off-by: Jakub Mucha <[email protected]>
  • Loading branch information
drptbl committed Nov 1, 2021
1 parent 796fcc1 commit ee7a3c7
Showing 1 changed file with 15 additions and 8 deletions.
23 changes: 15 additions & 8 deletions commands/metamask.js
Original file line number Diff line number Diff line change
Expand Up @@ -261,14 +261,21 @@ module.exports = {
addNetworkPageElements.chainIdInput,
network.chainId,
);
await puppeteer.waitAndType(
addNetworkPageElements.symbolInput,
network.symbol,
);
await puppeteer.waitAndType(
addNetworkPageElements.blockExplorerInput,
network.blockExplorer,
);

if (network.symbol) {
await puppeteer.waitAndType(
addNetworkPageElements.symbolInput,
network.symbol,
);
}

if (network.blockExplorer) {
await puppeteer.waitAndType(
addNetworkPageElements.blockExplorerInput,
network.blockExplorer,
);
}

await puppeteer.waitAndClick(addNetworkPageElements.saveButton);
await puppeteer.waitAndClick(settingsPageElements.closeButton);
await puppeteer.waitForText(
Expand Down

0 comments on commit ee7a3c7

Please sign in to comment.