Skip to content

Commit 0d50120

Browse files
committed
fix comments npe
1 parent 97bfb45 commit 0d50120

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

src/vs/workbench/api/node/extHostComments.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -270,12 +270,12 @@ function convertToComment(provider: vscode.DocumentCommentProvider | vscode.Work
270270
canDelete: canDelete,
271271
command: vscodeComment.command ? commandsConverter.toInternal(vscodeComment.command) : null,
272272
isDraft: vscodeComment.isDraft,
273-
commentReactions: vscodeComment.commentReactions.map(reaction => {
273+
commentReactions: vscodeComment.commentReactions ? vscodeComment.commentReactions.map(reaction => {
274274
return {
275275
label: reaction.label,
276276
hasReacted: reaction.hasReacted,
277277
canEdit: (reaction.hasReacted && providerCanDeleteReaction) || (!reaction.hasReacted && providerCanAddReaction)
278278
};
279-
})
279+
}) : undefined
280280
};
281281
}

0 commit comments

Comments
 (0)