We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 7529c54 commit d0e7273Copy full SHA for d0e7273
src/murfey/client/destinations.py
@@ -20,12 +20,12 @@ def find_longest_data_directory(
20
Determine the longest path in the data_directories list
21
which the match path is relative to
22
"""
23
- base_dir = ""
+ base_dir = Path("")
24
mid_dir = Path("")
25
for dd in data_directories:
26
dd_base = str(Path(dd).absolute())
27
- if str(match_path).startswith(str(dd)) and len(dd_base) > len(base_dir):
28
- base_dir = dd_base
+ if str(match_path).startswith(str(dd)) and len(dd_base) > len(str(base_dir)):
+ base_dir = Path(dd_base)
29
mid_dir = match_path.absolute().relative_to(Path(base_dir)).parent
30
return base_dir, mid_dir
31
0 commit comments