mirror of
https://github.com/github/awesome-copilot.git
synced 2026-06-14 20:05:15 +00:00
Potential fix for pull request finding
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
This commit is contained in:
@@ -270,9 +270,15 @@ function toMarkdownReport(findings, scannedFiles, skippedFiles) {
|
||||
: finding.severity === severityLevels.medium
|
||||
? "🟠"
|
||||
: "ℹ️";
|
||||
const match = finding.match.replace(/\|/g, "\\|");
|
||||
const match = finding.match
|
||||
.replace(/\\/g, "\\\\")
|
||||
.replace(/`/g, "\\`")
|
||||
.replace(/</g, "<")
|
||||
.replace(/>/g, ">")
|
||||
.replace(/\|/g, "\\|")
|
||||
.replace(/@/g, "@\u200b");
|
||||
summary.push(
|
||||
`| ${severity} | \`${finding.rule_id}\` | \`${finding.file}\` | ${finding.line} | ${match} |`
|
||||
`| ${severity} | \`${finding.rule_id}\` | \`${finding.file}\` | ${finding.line} | \`${match}\` |`
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user