From 7185609213f15bc50fdc8603aa7bf75c68365563 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?In=C3=AAs=20Martins?= Date: Thu, 16 Nov 2023 09:41:37 +0000 Subject: [PATCH] [feat] removes logs, adds condition --- dojo/finding/views.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/dojo/finding/views.py b/dojo/finding/views.py index 71051ab606..00d9f8929c 100644 --- a/dojo/finding/views.py +++ b/dojo/finding/views.py @@ -969,7 +969,6 @@ def process_finding_form(self, request: HttpRequest, finding: Finding, context: new_finding.tags = context["form"].cleaned_data["tags"] # Handle verified date if new_finding.verified is True and new_finding.verified_date is None: - logger.error('Updates verification date on process_finding_form') new_finding.verified_date = timezone.now() # Handle group related things if "group" in context["form"].cleaned_data: @@ -1342,7 +1341,8 @@ def defect_finding_review(request, fid): else: finding.active = True finding.verified = True - finding.verified_date = now + if finding.verified_date is None: + finding.verified_date = now finding.mitigated = None finding.mitigated_by = None finding.is_mitigated = False @@ -2090,7 +2090,6 @@ def promote_to_finding(request, fid): new_finding.mitigated = None new_finding.verified = True if new_finding.verified_date is None: - logger.error('Updates verification date on promote_to_finding') new_finding.verified_date = timezone.now() new_finding.out_of_scope = False