Accomodate LibraryStatements in instrumentSolidity.js

pull/1/head
cgewecke 8 years ago
parent 3e53edc87f
commit 0b57ebc8df
  1. 3
      instrumentSolidity.js

@ -41,7 +41,8 @@ module.exports = function instrumentSolidity(contractSource, fileName) {
ast = SolidityParser.parse(contract.preprocessed);
const contractStatement = ast.body.filter(node => node.type === 'ContractStatement');
const contractStatement = ast.body.filter(node => (node.type === 'ContractStatement' ||
node.type === 'LibraryStatement'));
contract.contractName = contractStatement[0].name;
parse[ast.type](contract, ast);

Loading…
Cancel
Save