Skip to content

Commit 526e0aa

Browse files
authored
Optimize the analysis of get plugins (#716)
* Optimize the analysis of get plugins * update var
1 parent 2bbbbe7 commit 526e0aa

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

backend/plugin/tools.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ def get_plugins() -> list[str]:
4646

4747
# 遍历插件目录
4848
for item in os.listdir(PLUGIN_DIR):
49-
if item.endswith('.py') or item.endswith('backup') or item == '__pycache__':
49+
if not os.path.isdir(os.path.join(PLUGIN_DIR, item)) and item == '__pycache__':
5050
continue
5151

5252
item_path = os.path.join(PLUGIN_DIR, item)

0 commit comments

Comments
 (0)