Skip to content

Commit b137b6e

Browse files
committed
fix: ensure CSP shows up as skipped
Fixes that we were showing "0 violations" instead of "Skipped" when there's no CSP data.
1 parent b558781 commit b137b6e

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

runner/builder/puppeteer.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,9 @@ export async function runAppInPuppeteer(
2323
enableAutoCsp: boolean
2424
) {
2525
const runtimeErrors: string[] = [];
26-
let cspViolations: CspViolation[] = [];
26+
27+
// Undefined by default so it gets flagged correctly as `skipped` if there's no data.
28+
let cspViolations: CspViolation[] | undefined;
2729
let screenshotBase64Data: string | undefined;
2830
let axeViolations: Result[] | undefined;
2931

0 commit comments

Comments
 (0)