Redact deleted issue comments

This commit is contained in:
Dotta
2026-06-03 17:32:25 +00:00
parent 78dc3625ac
commit 7f70759e61
27 changed files with 20722 additions and 83 deletions
+3 -1
View File
@@ -1607,7 +1607,9 @@ export function createTestHarness(options: TestHarnessOptions): TestHarness {
async listComments(issueId, companyId) {
requireCapability(manifest, capabilitySet, "issue.comments.read");
if (!isInCompany(issues.get(issueId), companyId)) return [];
return issueComments.get(issueId) ?? [];
return (issueComments.get(issueId) ?? []).map((comment) =>
comment.deletedAt ? { ...comment, body: "", presentation: null, metadata: null } : comment
);
},
async createComment(issueId, body, companyId, options) {
requireCapability(manifest, capabilitySet, "issue.comments.create");