summaryrefslogtreecommitdiffstats
path: root/ui/src/components/comment-form.tsx
diff options
context:
space:
mode:
authorDessalines <tyhou13@gmx.com>2020-07-01 20:38:11 -0400
committerDessalines <tyhou13@gmx.com>2020-07-01 20:38:11 -0400
commit2e886ce4e62e6788554d165cd7024e4618ea49a5 (patch)
tree57db2a67f6b32471c692c0c657e842ba2320d497 /ui/src/components/comment-form.tsx
parent360e7aec424ca07a0329e18549f8dce692495ed8 (diff)
Nother fix for comment box bug. #861
Diffstat (limited to 'ui/src/components/comment-form.tsx')
-rw-r--r--ui/src/components/comment-form.tsx4
1 files changed, 3 insertions, 1 deletions
diff --git a/ui/src/components/comment-form.tsx b/ui/src/components/comment-form.tsx
index 72a604b9..61ee3d77 100644
--- a/ui/src/components/comment-form.tsx
+++ b/ui/src/components/comment-form.tsx
@@ -263,7 +263,9 @@ export class CommentForm extends Component<CommentFormProps, CommentFormState> {
// If its a comment edit, only check that its from your user, and that its a
// text edit only
- (op == UserOperation.EditComment && data.comment.content)
+ (data.comment.creator_id == UserService.Instance.user.id &&
+ op == UserOperation.EditComment &&
+ data.comment.content)
) {
this.state.previewMode = false;
this.state.loading = false;