From 5c9320ac818cbdfe0dea6e0f72912ff2c6912c1e Mon Sep 17 00:00:00 2001 From: j2rong4cn Date: Mon, 1 Jun 2026 18:22:02 +0800 Subject: [PATCH] fix(hooks): Ignore 403 errors in list-only mode --- src/hooks/usePath.ts | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/hooks/usePath.ts b/src/hooks/usePath.ts index 386b558af..96e6b3877 100644 --- a/src/hooks/usePath.ts +++ b/src/hooks/usePath.ts @@ -182,7 +182,13 @@ export const usePath = () => { ObjStore.setDirectUploadTools(data.direct_upload_tools) shouldKeepState() || ObjStore.setState(State.Folder) }, - handleErr, + onlyList + ? (msg: string, code?: number) => { + if (code !== 403) { + handleErr(msg, code) + } + } + : handleErr, ) }