Commit 10074d36 by James Cammarata

Fix linking issue to directories in file module

The os.path.isdir() returns True for symlinks that point to directories,
so we also need to check to make sure it's not a symlink too.

Fixes #7657
parent 2625196f
......@@ -182,7 +182,7 @@ def main():
elif state in ['link','hard']:
if os.path.isdir(path):
if os.path.isdir(path) and not os.path.islink(path):
relpath = path
else:
relpath = os.path.dirname(path)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment