Skip to content

Commit 20c1e0d

Browse files
fix(dashboard): escape author field in revision table (#1001)
## Summary - wraps the `author` column in `dashboard revisions` with `escapeMarkdownCell()` to prevent markdown table breakage when a user's name or email contains `|` - missed in #1000 — caught by sentry[bot]'s automated review One-line change, no new dependencies.
1 parent 0a8d7d0 commit 20c1e0d

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

src/commands/dashboard/revisions.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,9 @@ function formatRevisionsHuman(result: RevisionsResult): string {
7272
const rows: RevisionRow[] = result.revisions.map((r) => ({
7373
id: r.id,
7474
title: escapeMarkdownCell(r.title),
75-
author: r.createdBy?.name ?? r.createdBy?.email ?? r.createdBy?.id ?? "—",
75+
author: escapeMarkdownCell(
76+
r.createdBy?.name ?? r.createdBy?.email ?? r.createdBy?.id ?? "—"
77+
),
7678
created: `${escapeMarkdownCell(formatRelativeTime(r.dateCreated))}\n${colorTag("muted", r.dateCreated)}`,
7779
}));
7880

0 commit comments

Comments
 (0)