diff --git a/src/transformer.ts b/src/transformer.ts index a8a8908..8cea7ff 100644 --- a/src/transformer.ts +++ b/src/transformer.ts @@ -20,7 +20,7 @@ const identifierProgram = (program: ts.Program, options: any) => { console.log(`Type symbol: ${type.localSymbol?.name} : ${type.id} : ${type.getText()}`) // eslint-disable-line no-console for ( const decl of interfaceDeclarations ) { - if ( decl.name.symbol === (type as any).typeName.symbol ) { + if ( decl?.name?.symbol === (type as any)?.typeName?.symbol ) { console.log(`Match to interface: ${decl.name.text}`) // eslint-disable-line no-console console.log(decl) // eslint-disable-line no-console