From fe6616941505b82d503899e2e27d5a2e95f39db3 Mon Sep 17 00:00:00 2001 From: Jonathan Baird Date: Thu, 9 Apr 2020 12:46:24 -0600 Subject: fix bug that prevents editing or deleting comments --- client/components/activities/activities.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'client') diff --git a/client/components/activities/activities.js b/client/components/activities/activities.js index 36214e19..5d356f6e 100644 --- a/client/components/activities/activities.js +++ b/client/components/activities/activities.js @@ -180,7 +180,7 @@ BlazeComponent.extendComponent({ { // XXX We should use Popup.afterConfirmation here 'click .js-delete-comment'() { - const commentId = this.currentData().commentId; + const commentId = this.currentData().activity.commentId; CardComments.remove(commentId); }, 'submit .js-edit-comment'(evt) { @@ -188,7 +188,7 @@ BlazeComponent.extendComponent({ const commentText = this.currentComponent() .getValue() .trim(); - const commentId = Template.parentData().commentId; + const commentId = Template.parentData().activity.commentId; if (commentText) { CardComments.update(commentId, { $set: { -- cgit v1.2.3-1-g7c22