提交 0d50120c 编写于 作者: P Peng Lyu

fix comments npe

上级 97bfb45f
......@@ -270,12 +270,12 @@ function convertToComment(provider: vscode.DocumentCommentProvider | vscode.Work
canDelete: canDelete,
command: vscodeComment.command ? commandsConverter.toInternal(vscodeComment.command) : null,
isDraft: vscodeComment.isDraft,
commentReactions: vscodeComment.commentReactions.map(reaction => {
commentReactions: vscodeComment.commentReactions ? vscodeComment.commentReactions.map(reaction => {
return {
label: reaction.label,
hasReacted: reaction.hasReacted,
canEdit: (reaction.hasReacted && providerCanDeleteReaction) || (!reaction.hasReacted && providerCanAddReaction)
};
})
}) : undefined
};
}
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册