diff --git a/src/smartcontracts/typesystem/abiRegistry.ts b/src/smartcontracts/typesystem/abiRegistry.ts index 1438db5c..7bdded62 100644 --- a/src/smartcontracts/typesystem/abiRegistry.ts +++ b/src/smartcontracts/typesystem/abiRegistry.ts @@ -11,13 +11,13 @@ export class AbiRegistry { readonly interfaces: ContractInterface[] = []; private customTypes: CustomType[] = []; - static create(json: { name: string; endpoints: any[]; types: any[] }): AbiRegistry { + static create(json: { name: string; endpoints: any[]; types: Record }): AbiRegistry { let registry = new AbiRegistry().extend(json); let remappedRegistry = registry.remapToKnownTypes(); return remappedRegistry; } - private extend(json: { name: string; endpoints: any[]; types: any[] }): AbiRegistry { + private extend(json: { name: string; endpoints: any[]; types: Record }): AbiRegistry { json.types = json.types || {}; // The "endpoints" collection is interpreted by "ContractInterface".