Skip to content

Commit 28bc084

Browse files
committed
adding sanitisation
1 parent 578f88d commit 28bc084

File tree

2 files changed

+3
-0
lines changed

2 files changed

+3
-0
lines changed

browserstack-report-action/dist/index.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38235,6 +38235,7 @@ class ReportProcessor {
3823538235
let addToSummaryReport = this.reportData?.report?.basicHtml;
3823638236
if (addToSummaryReport) {
3823738237
addToSummaryReport = `<html>${addToSummaryReport}</html>`;
38238+
addToSummaryReport = addToSummaryReport.replace(/[\u201C\u201D]/g, '"');
3823838239
core.info(`Report HTML: ${addToSummaryReport}`);
3823938240
await summary.addRaw(addToSummaryReport, false);
3824038241
} else {

browserstack-report-action/src/services/ReportProcessor.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,8 @@ class ReportProcessor {
1414
let addToSummaryReport = this.reportData?.report?.basicHtml;
1515
if (addToSummaryReport) {
1616
addToSummaryReport = `<html>${addToSummaryReport}</html>`;
17+
//remove curly quotes with normal double quotes
18+
addToSummaryReport = addToSummaryReport.replace(/[\u201C\u201D]/g, '"');
1719
core.info(`Report HTML: ${addToSummaryReport}`);
1820
await summary.addRaw(addToSummaryReport, false);
1921
} else {

0 commit comments

Comments
 (0)