diff --git a/core/frontend/src/api.ts b/core/frontend/src/api.ts index d6ced6d..f6f0e60 100644 --- a/core/frontend/src/api.ts +++ b/core/frontend/src/api.ts @@ -132,6 +132,10 @@ async function request(path: string, options: RequestInit = {}): Promise { if (response.status === 401 && AUTH_MISSING_MESSAGES.has(message)) { message = FRIENDLY_AUTH_MISSING_MESSAGE; } + // 团队接口统一用此 403 表示当前账号不具备操作资格;只翻译精确原文,避免掩盖其他 403 原因。 + if (response.status === 403 && message === "permission denied") { + message = "当前账号权限不足"; + } throw new ApiError(response.status, message); } if (response.status === 204) return undefined as T;