From c9daafd5f7438940f4657c9742159fcfb3fc426a Mon Sep 17 00:00:00 2001 From: einsitang Date: Thu, 5 Sep 2024 01:07:06 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=AD=A3=E9=94=99=E8=AF=AF=E9=80=BB?= =?UTF-8?q?=E8=BE=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 修正算法 --- src/components/proxy/use-render-list.ts | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/components/proxy/use-render-list.ts b/src/components/proxy/use-render-list.ts index b9efe5a..7b44a8d 100644 --- a/src/components/proxy/use-render-list.ts +++ b/src/components/proxy/use-render-list.ts @@ -79,13 +79,16 @@ export const useRenderList = (mode: string) => { if (hiddenInvalidNetwork) { let proxys = group.all.filter((item) => { if (item.all) { - return false; + return true; } if (item.history) { const history = item.history; let min = Math.min(3, history.length); - let recentHistory = history.slice(0, min); + let recentHistory = history.slice( + history.length - min, + history.length + ); let hasInvalidNetwork = recentHistory.filter((item) => item.delay == 0).length > 0; if (hasInvalidNetwork) {