Skip to content

Commit 99343b3

Browse files
committed
CM-50645 - Fix secrets commit history scan
1 parent a838ebd commit 99343b3

File tree

2 files changed

+275
-6
lines changed

2 files changed

+275
-6
lines changed

cycode/cli/files_collector/commit_range_documents.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -193,7 +193,10 @@ def get_diff_file_path(diff: 'Diff', relative: bool = False) -> Optional[str]:
193193

194194
if diff.b_blob:
195195
return diff.b_blob.abspath
196-
return diff.a_blob.abspath
196+
if diff.a_blob:
197+
return diff.a_blob.abspath
198+
199+
return None
197200

198201

199202
def get_diff_file_content(diff: 'Diff') -> str:

0 commit comments

Comments
 (0)