diff --git a/server/src/core/server/stacks/editComment.ts b/server/src/core/server/stacks/editComment.ts index 78e4f559b8..3baf17180f 100644 --- a/server/src/core/server/stacks/editComment.ts +++ b/server/src/core/server/stacks/editComment.ts @@ -103,7 +103,7 @@ export default async function edit( throw new CommentNotFoundError(input.id); } - // If the original comment was a reply, then get it's parent! + // If the original comment was a reply, then get its parent! const { parentID, parentRevisionID, siteID } = originalStaleComment; const parent = await retrieveParent(mongo, tenant.id, { parentID, diff --git a/server/src/core/server/stacks/helpers/retrieveParent.ts b/server/src/core/server/stacks/helpers/retrieveParent.ts index 19798d1900..b55d641053 100644 --- a/server/src/core/server/stacks/helpers/retrieveParent.ts +++ b/server/src/core/server/stacks/helpers/retrieveParent.ts @@ -5,7 +5,6 @@ import { ParentCommentRejectedError, } from "coral-server/errors"; import { - getLatestRevision, hasPublishedStatus, retrieveComment, } from "coral-server/models/comment"; @@ -31,13 +30,6 @@ async function retrieveParent( throw new CommentNotFoundError(input.parentID); } - // Check to see that the most recent revision matches the one we just replied - // to. - const revision = getLatestRevision(parent); - if (revision.id !== input.parentRevisionID) { - throw new CommentRevisionNotFoundError(parent.id, input.parentRevisionID); - } - // Check that the parent comment was visible. if (!hasPublishedStatus(parent)) { if (parent.status === GQLCOMMENT_STATUS.REJECTED) {