Comparing version 0.0.30 to 0.0.31
@@ -107,6 +107,10 @@ #! /usr/bin/env node | ||
let stateMutability = ""; | ||
if (contractABI[i]?.stateMutability != "nonpayable") { | ||
stateMutability = contractABI[i].stateMutability; | ||
if (contractABI[i]?.stateMutability != null | ||
&& contractABI[i]?.stateMutability != "nonpayable") { | ||
stateMutability = " " + contractABI[i].stateMutability; | ||
} | ||
fnInterfaces += `) external ${stateMutability}`; | ||
fnInterfaces += `)`; | ||
if (contractABI[i].type == "function") { | ||
fnInterfaces += ` external${stateMutability}`; | ||
} | ||
const outputs = contractABI[i].outputs; | ||
@@ -127,4 +131,5 @@ if (outputs?.length > 0) { | ||
} | ||
fnInterfaces += `);`; | ||
fnInterfaces += `)`; | ||
} | ||
fnInterfaces += `;`; | ||
if (i < contractABI.length - 1) { | ||
@@ -131,0 +136,0 @@ fnInterfaces += `\n`; |
13
index.ts
@@ -104,6 +104,10 @@ #! /usr/bin/env node | ||
let stateMutability = "" | ||
if(contractABI[i]?.stateMutability != "nonpayable"){ | ||
stateMutability = contractABI[i].stateMutability | ||
if(contractABI[i]?.stateMutability != null | ||
&& contractABI[i]?.stateMutability != "nonpayable"){ | ||
stateMutability = " "+contractABI[i].stateMutability | ||
} | ||
fnInterfaces += `) external ${stateMutability}` | ||
fnInterfaces += `)` | ||
if(contractABI[i].type == "function"){ | ||
fnInterfaces += ` external${stateMutability}` | ||
} | ||
const outputs = contractABI[i].outputs | ||
@@ -124,5 +128,6 @@ if(outputs?.length > 0){ | ||
} | ||
fnInterfaces += `);` | ||
fnInterfaces += `)` | ||
} | ||
fnInterfaces += `;` | ||
if(i < contractABI.length-1){ | ||
@@ -129,0 +134,0 @@ fnInterfaces += `\n` |
{ | ||
"name": "soleasy", | ||
"version": "0.0.30", | ||
"version": "0.0.31", | ||
"description": "Make solidity so easy", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
17793
380