diff --git a/src/app/components/shared/comment/comment.component.html b/src/app/components/shared/comment/comment.component.html index 5dbdc15ff623535e8910791e3bce00e5ebe47b71..00e76cf6c3cc6a9cd125a222bf40975907d18fa3 100644 --- a/src/app/components/shared/comment/comment.component.html +++ b/src/app/components/shared/comment/comment.component.html @@ -53,7 +53,8 @@ </mat-icon> </button> <button mat-icon-button - *ngIf="(isCreator || comment.creatorId === user.id) && !comment.favorite && !inAnswerView" (click)="openDeleteCommentDialog()" + *ngIf="(isCreator || (comment.creatorId && user && comment.creatorId === user.id)) && !comment.favorite && !inAnswerView" + (click)="openDeleteCommentDialog()" tabindex="0" attr.aria-labelledby="comment_delete{{ comment.id }}"> <mat-icon class="not-marked" matTooltip="{{ 'comment-page.delete' | translate }}">delete </mat-icon>