🚑fix(data_source): 修复插件商店更新路径错误 (#2056)

* 🚑fix(data_source): 修复插件商店更新路径错误

* fix(plugin_store): 修复插件模块路径处理逻辑

简化了插件模块路径的赋值逻辑,直接使用插件对象的模块路径,避免不必要的路径分割操作。
同时修复了目标目录判断条件,确保只有在模块路径为根目录时才使用插件名称作为目录。
This commit is contained in:
molanp 2025-09-28 08:50:54 +08:00 committed by GitHub
parent 3cc882b116
commit 7e6896fa01
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -287,7 +287,7 @@ class StoreManager:
files = [RepoFileInfo(path=f"{replace_module_path}.py", is_dir=False)]
if not is_external:
target_dir = BASE_PATH
elif is_dir:
elif is_dir and module_path == ".":
target_dir = BASE_PATH / "plugins" / plugin_name
else:
target_dir = BASE_PATH / "plugins"