Skip to content

Commit

Permalink
Handle case when value signature is undefined
Browse files Browse the repository at this point in the history
  • Loading branch information
olafurpg committed Apr 19, 2024
1 parent 742ab0a commit 88633db
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/FileIndexer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -461,7 +461,7 @@ export class FileIndexer {
(ts.isPropertyDeclaration(declaration) && declaration.questionToken) ||
(ts.isPropertySignature(declaration) && declaration.questionToken)
)
if (isOptional) {
if (isOptional && signature.value_signature.tpe !== undefined) {
signature.value_signature.tpe = this.makeOptional(
signature.value_signature.tpe
)
Expand Down

0 comments on commit 88633db

Please sign in to comment.