fix 更新软连接指向

This commit is contained in:
thsrite
2024-06-21 17:05:53 +08:00
parent ec950e0a97
commit 4d5b11d281

View File

@@ -485,7 +485,7 @@ class CloudAssistant(_PluginBase):
path = os.path.join(root, name)
if os.path.islink(path):
current_target = os.readlink(path)
if current_target == target_from:
if str(current_target).startswith(target_from):
new_target = current_target.replace(target_from, target_to)
os.remove(path)
os.symlink(new_target, path)