Skip to content

Commit a1822f8

Browse files
committed
reset index.js
1 parent 2db25fc commit a1822f8

File tree

1 file changed

+0
-20
lines changed
  • target_chains/ethereum/abi_generator/src

1 file changed

+0
-20
lines changed

target_chains/ethereum/abi_generator/src/index.js

Lines changed: 0 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -42,29 +42,9 @@ function generateAbi(contracts) {
4242
fs.mkdirSync("abis");
4343
}
4444

45-
if (output.errors) {
46-
// We can still generate ABIs with warnings, only throw for errors
47-
const errors = output.errors.filter((e) => e.severity === "error");
48-
if (errors.length > 0) {
49-
console.error("Compilation errors:");
50-
for (const error of errors) {
51-
console.error(error.formattedMessage || error.message);
52-
}
53-
throw new Error("Compilation failed due to errors");
54-
}
55-
}
56-
57-
5845
for (let contract of contracts) {
5946
const contractFile = `${contract}.sol`;
6047

61-
if (!output.contracts[contractFile]) {
62-
throw new Error(`Unable to produce ABI for ${contractFile}.`);
63-
}
64-
if (!output.contracts[contractFile][contract]) {
65-
throw new Error(`Unable to produce ABI for ${contractFile}:${contract}.`);
66-
}
67-
6848
const abi = output.contracts[contractFile][contract].abi;
6949
fs.writeFileSync(
7050
`abis/${contract}.json`,

0 commit comments

Comments
 (0)