Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
babenek committed Oct 25, 2022
1 parent 4e77dc9 commit f17cbbd
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions credsweeper/app.py
Expand Up @@ -268,8 +268,8 @@ def file_scan(self, content_provider: ContentProvider) -> List[Candidate]:
extra_candidates = self.data_scan(data_provider, self.config.depth, RECURSIVE_SCAN_LIMITATION)
if extra_candidates:
# reduce duplicated credentials
found_values = set(
line_data.value for candidate in candidates for line_data in candidate.line_data_list)
found_values = set(line_data.value for candidate in candidates
for line_data in candidate.line_data_list)
for i in extra_candidates:
for j in i.line_data_list:
if j.value not in found_values:
Expand Down
2 changes: 1 addition & 1 deletion credsweeper/file_handler/data_content_provider.py
Expand Up @@ -31,7 +31,7 @@ def __init__(
super().__init__(file_path=file_path, file_type=file_type, info=info)
self.data = data
self.decoded: Optional[bytes] = None
self.lines = []
self.lines: List[str] = []

@property
def data(self) -> bytes:
Expand Down
6 changes: 3 additions & 3 deletions tests/__init__.py
Expand Up @@ -11,9 +11,9 @@
SAMPLES_POST_CRED_COUNT: int = 20

# archived credentials that not found without --depth
SAMPLES_IN_DEEP_1 = 5
SAMPLES_IN_DEEP_2 = 6
SAMPLES_IN_DEEP_3 = 7
SAMPLES_IN_DEEP_1 = 6
SAMPLES_IN_DEEP_2 = 7
SAMPLES_IN_DEEP_3 = 8

SAMPLES_FILTERED_BY_POST_COUNT = 1

Expand Down

0 comments on commit f17cbbd

Please sign in to comment.