Skip to content

Commit

Permalink
Lint styling.
Browse files Browse the repository at this point in the history
  • Loading branch information
costastf committed Dec 12, 2023
1 parent 613e7ec commit e24998e
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions awsfindingsmanagerlib/awsfindingsmanagerlib.py
Original file line number Diff line number Diff line change
Expand Up @@ -252,6 +252,7 @@ def _validate_type(type_):
raise InvalidRuleType(type_)
return type_


class FindingsManager:
"""Models security hub and can retrieve findings."""

Expand Down Expand Up @@ -292,9 +293,6 @@ def register_rules(self, rules):
self._logger.exception(f'Rule with data {data} is invalid')
return success




def _validate_region(self, region):
if any([not region, region in self.regions]):
return region
Expand Down Expand Up @@ -464,7 +462,8 @@ def get_findings_by_control_id(self, control_id):
findings (list): A list of findings from security hub.
"""
query_filter = {'ProductFields': [{'Key': 'ControlId', 'Value': control_id, 'Comparison': 'EQUALS'}]} #controlid == ruleid
query_filter = {
'ProductFields': [{'Key': 'ControlId', 'Value': control_id, 'Comparison': 'EQUALS'}]} # controlid == ruleid
return self._get_findings(query_filter)

def get_findings_by_tag(self):
Expand Down

0 comments on commit e24998e

Please sign in to comment.