Skip to content
This repository was archived by the owner on Feb 26, 2024. It is now read-only.

Commit 341a7f5

Browse files
committed
Remove invalid networks check from Sourcify fetcher
1 parent cc26d74 commit 341a7f5

File tree

1 file changed

+3
-7
lines changed

1 file changed

+3
-7
lines changed

packages/source-fetcher/lib/sourcify.ts

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ const debug = debugModule("source-fetcher:sourcify");
33

44
import type { Fetcher, FetcherConstructor } from "./types";
55
import type * as Types from "./types";
6-
import { removeLibraries, InvalidNetworkError } from "./common";
6+
import { removeLibraries } from "./common";
77
import { networkNamesById, networksByName } from "./networks";
88
import retry from "async-retry";
99

@@ -164,12 +164,8 @@ const SourcifyFetcher: FetcherConstructor = class SourcifyFetcher
164164
constructor(networkId: number) {
165165
this.networkId = networkId;
166166
this.networkName = networkNamesById[networkId];
167-
if (
168-
this.networkName === undefined ||
169-
!SourcifyFetcher.supportedNetworks.has(this.networkName)
170-
) {
171-
throw new InvalidNetworkError(networkId, "sourcify");
172-
}
167+
//we no longer check if the network is supported; the list is now only
168+
//used for if you explicitly ask
173169
}
174170

175171
static getSupportedNetworks(): Types.SupportedNetworks {

0 commit comments

Comments
 (0)