perf: Optimize API documentation authentication prompts

This commit is contained in:
fit2cloud-chenyw
2026-02-09 16:58:07 +08:00
committed by fit2cloud-chenyw
parent 6176eee385
commit 95a7daebef
+2 -1
View File
@@ -41747,7 +41747,8 @@
}
if (!a.ok) {
const s = new Error(a.statusText || `response status is ${a.status}`)
if (a.status === 401 && a.statusText === 'Unauthorized') {
// if (a.status === 401 && a.statusText === 'Unauthorized') {
if (a.status === 401) {
location.href = location.pathname.replace('/docs', '/') + '#/401?title=unauthorized&target=docs'
return a
}