fix: enforce optional manifest fields
This commit is contained in:
@@ -159,7 +159,9 @@ function assertExactSchema(manifest) {
|
||||
|
||||
function assertManifestUrls(manifest, spec) {
|
||||
if (manifest.network === "anvil") {
|
||||
if (manifest.rpcUrl !== spec.rpcUrl) throw new Error("manifest anvil rpcUrl must use the local public endpoint");
|
||||
if (Object.hasOwn(manifest, "rpcUrl") && manifest.rpcUrl !== spec.rpcUrl) {
|
||||
throw new Error("manifest anvil rpcUrl must use the local public endpoint");
|
||||
}
|
||||
if (Object.hasOwn(manifest, "explorerBaseUrl")) throw new Error("manifest anvil must omit explorerBaseUrl");
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user