Skip to content

Commit 52738a0

Browse files
committed
fix(filetree): Relative path is always without a root slash
1 parent cd0ad80 commit 52738a0

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/bids_validator/types/files.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -118,9 +118,9 @@ def relative_path(self) -> str:
118118
Directories include trailing slashes for simpler matching.
119119
"""
120120
if self.parent is None:
121-
return '/'
121+
return ''
122122

123123
return posixpath.join(
124124
self.parent.relative_path,
125125
f'{self.name}/' if self.is_dir else self.name,
126-
)[1:]
126+
)

0 commit comments

Comments
 (0)