Skip to content

Commit

Permalink
always use 'document-uri' and always set an URL
Browse files Browse the repository at this point in the history
  • Loading branch information
fritzmg committed Jan 15, 2024
1 parent 25ad7c7 commit 8f892e0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion core-bundle/src/EventListener/CspReportListener.php
Expand Up @@ -35,7 +35,7 @@ public function __invoke(ReportEvent $event): void
__METHOD__,
ContaoContext::ERROR,
browser: $report->getUserAgent(),
uri: $report->getSourceFile(),
uri: $report->getData()['document-uri'] ?? '',
);

$msg = sprintf('Content-Security-Policy violation reported for "%s"', $report->getDirective());
Expand Down

0 comments on commit 8f892e0

Please sign in to comment.