From 163bb8875118b713de32d6dd1205559722ec8bb8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=89=8B=E7=93=9C=E4=B8=80=E5=8D=81=E9=9B=AA?= Date: Sat, 17 Jan 2026 16:27:24 +0800 Subject: [PATCH] Remove unused isFile variable in GetPluginListHandler Cleaned up the GetPluginListHandler by removing the unused isFile variable, as it was no longer needed for plugin list processing. --- packages/napcat-webui-backend/src/api/Plugin.ts | 2 -- 1 file changed, 2 deletions(-) diff --git a/packages/napcat-webui-backend/src/api/Plugin.ts b/packages/napcat-webui-backend/src/api/Plugin.ts index ab6b7651..74014641 100644 --- a/packages/napcat-webui-backend/src/api/Plugin.ts +++ b/packages/napcat-webui-backend/src/api/Plugin.ts @@ -60,11 +60,9 @@ export const GetPluginListHandler: RequestHandler = async (_req, res) => { for (const item of items) { let id = ''; - let isFile = false; if (item.isFile()) { if (!['.js', '.mjs'].includes(path.extname(item.name))) continue; - isFile = true; id = getPluginId(item.name, true); } else if (item.isDirectory()) { id = getPluginId(item.name, false);