Skip to content

Commit

Permalink
Bug: The cursor must be within a commenting range to add a comment. (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
alexr00 authored Dec 19, 2024
1 parent b392dd9 commit 41a58be
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/vs/workbench/contrib/comments/browser/commentNode.ts
Original file line number Diff line number Diff line change
Expand Up @@ -457,7 +457,7 @@ export class CommentNode<T extends IRange | ICellRange> extends Disposable {
this._register(this._reactionsActionBar);

const hasReactionHandler = this.commentService.hasReactionHandler(this.owner);
this.comment.commentReactions!.filter(reaction => !!reaction.count).map(reaction => {
this.comment.commentReactions?.filter(reaction => !!reaction.count).map(reaction => {
const action = new ReactionAction(`reaction.${reaction.label}`, `${reaction.label}`, reaction.hasReacted && (reaction.canEdit || hasReactionHandler) ? 'active' : '', (reaction.canEdit || hasReactionHandler), async () => {
try {
await this.commentService.toggleReaction(this.owner, this.resource, this.commentThread, this.comment, reaction);
Expand Down

0 comments on commit 41a58be

Please sign in to comment.