Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
def add_finding(self, finding, severity, location={}):
"""
Add finding to the class.
finding: String specifiying the problem
severity: misc.severity identifier
location: Dictionary with information about where this problem is. Often set to:
{"location": "string"}
"""
self.findings.append(Finding(finding, severity, location))
def add_finding(self, finding, detail=None, location={}):
"""
Add finding to the class.
finding: String specifiying the problem
location: Dictionary with information about where this problem is. Often set to:
{"location": "string"}
"""
self.findings.append(Finding(finding, detail, location))
def add_finding(self, finding, detail="", location={}):
if "filepath" not in location:
location["filepath"] = self.filepath
self._findings.append(Finding(finding, detail, location))
def add_finding(self, finding, severity, location={}):
if "filepath" not in location:
location["filepath"] = self.filepath
self._findings.append(Finding(finding, severity, location))