From da7c2519186c5f717848b21467f95c05fd8fc923 Mon Sep 17 00:00:00 2001 From: Dylan Maurits Date: Tue, 25 Jan 2022 11:16:33 +0100 Subject: [PATCH] [BUGFIX][SUBI-320] fixed bug where FallbackDirective was not being used properly --- Model/ReportRepository.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Model/ReportRepository.php b/Model/ReportRepository.php index 8ad2174..0b90f1f 100644 --- a/Model/ReportRepository.php +++ b/Model/ReportRepository.php @@ -156,10 +156,10 @@ public function save( if (!$existingReport) { try { if (!$this->canDirectiveBeWhitelisted($report->getFallbackDirective())) { - $report->setViolatedDirective($report->getFallbackDirective()); $report->setWhitelist(Whitelist::STATUS_NOT_ALLOWED); } + $report->setViolatedDirective($report->getFallbackDirective()); $report = $this->resource->save($report); } catch (Exception $exception) { throw new CouldNotSaveException(__(