Skip to content

Commit a965cb6

Browse files
committed
Silence redundant error
1 parent 8b5a222 commit a965cb6

File tree

3 files changed

+8
-3
lines changed

3 files changed

+8
-3
lines changed

packages/entrypoint/scripts/build.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ const PRODUCTION_URL = "https://code.deth.net";
99
const DEVELOPMENT_URL = "https://localhost:5001";
1010
const isProd = argv.production || process.env.CI === "true";
1111

12+
console.log("Building entrypoint...");
1213
console.log("Is production build? ", isProd);
1314

1415
rmSync("./dist", { recursive: true, force: true });

packages/entrypoint/src/index.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,8 @@ const { hostname, pathname, search } = window.location;
1212
url.pathname = pathname;
1313
url.search = search;
1414

15+
log("Starting on", { hostname, pathname, search });
16+
1517
// prefix of the hostname is passed to `explorer` search param
1618
// @see vscode-host/src/deth/commands/ethViewerCommands.ts
1719
if (hostname.endsWith(".deth.net") && !url.searchParams.get("explorer")) {

packages/ethereum-viewer/src/extension.ts

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -69,9 +69,11 @@ async function detectExplorerApiName(): Promise<explorer.ApiName> {
6969
if (!detectedName) return "etherscan";
7070

7171
if (!(detectedName in explorerApiUrls)) {
72-
await vscode.window.showErrorMessage(
73-
`"${detectedName}" is not a valid network. Using mainnet etherscan instead.`
74-
);
72+
if (detectedName !== "code") {
73+
await vscode.window.showErrorMessage(
74+
`"${detectedName}" is not a valid network. Using mainnet etherscan instead.`
75+
);
76+
}
7577

7678
return "etherscan";
7779
}

0 commit comments

Comments
 (0)