Skip to content

Commit f78f365

Browse files
Update src/licensedcode/detection.py
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
1 parent 26888c2 commit f78f365

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/licensedcode/detection.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1994,7 +1994,7 @@ def find_referenced_resource(referenced_filename, resource, codebase, **kwargs):
19941994
# Optimization: If we could limit walk to a subtree it would be better
19951995
# For now we walk all as a safe default
19961996
for res in codebase.walk(topdown=True):
1997-
if fnmatch(res.path, pattern):
1997+
if fnmatch(res.path, pattern) and not res.is_dir:
19981998
if res.path not in seen_paths:
19991999
matches.append(res)
20002000
seen_paths.add(res.path)

0 commit comments

Comments
 (0)