Comparing version 2.0.0 to 2.0.1
@@ -5,2 +5,3 @@ "use strict"; | ||
const umlClass_1 = require("./umlClass"); | ||
const associations_1 = require("./associations"); | ||
var StorageType; | ||
@@ -49,5 +50,5 @@ (function (StorageType) { | ||
newInheritedContracts.forEach((parent) => { | ||
const parentClass = umlClasses.find((umlClass) => umlClass.name === parent.targetUmlClassName); | ||
const parentClass = (0, associations_1.findAssociatedClass)(parent, umlClass, umlClasses); | ||
if (!parentClass) | ||
throw Error(`Failed to find parent contract ${parent.targetUmlClassName} of ${umlClass.name}`); | ||
throw Error(`Failed to find parent contract ${parent.targetUmlClassName} of ${umlClass.absolutePath}`); | ||
// recursively parse inherited contract | ||
@@ -54,0 +55,0 @@ parseStorage(parentClass, umlClasses, storages, storageObjects, inheritedContracts); |
@@ -104,4 +104,3 @@ #! /usr/bin/env node | ||
const { umlClasses, contractName } = await (0, parserGeneral_1.parserUmlClasses)(fileFolderAddress, combinedOptions); | ||
const filteredUmlClasses = (0, filterClasses_1.classesConnectedToBaseContracts)(umlClasses, [combinedOptions.contractName || contractName]); | ||
const storageObjects = (0, converterClasses2Storage_1.convertClasses2StorageObjects)(combinedOptions.contractName || contractName, filteredUmlClasses); | ||
const storageObjects = (0, converterClasses2Storage_1.convertClasses2StorageObjects)(combinedOptions.contractName || contractName, umlClasses); | ||
if ((0, regEx_1.isAddress)(fileFolderAddress)) { | ||
@@ -108,0 +107,0 @@ // The first object is the contract |
{ | ||
"name": "sol2uml", | ||
"version": "2.0.0", | ||
"version": "2.0.1", | ||
"description": "Unified Modeling Language (UML) class diagram generator for Solidity contracts", | ||
@@ -5,0 +5,0 @@ "main": "./lib/index.js", |
116638