mirror of
https://github.com/infiniflow/ragflow.git
synced 2026-08-02 05:47:31 +08:00
Feat: batch verify models in provider instance card (#17552)
This commit is contained in:
@@ -125,7 +125,8 @@ request.interceptors.response.use(
|
||||
}
|
||||
}
|
||||
|
||||
if (data?.code === 100) {
|
||||
const skipErrorNotification = (response.config as any)?.skipGlobalErrorNotification;
|
||||
if (data?.code === 100 && !skipErrorNotification) {
|
||||
message.error(data?.message);
|
||||
} else if (data?.code === 401) {
|
||||
if (!isRedirecting) {
|
||||
@@ -138,7 +139,7 @@ request.interceptors.response.use(
|
||||
authorizationUtil.removeAll();
|
||||
redirectToLogin();
|
||||
}
|
||||
} else if (data?.code !== 0) {
|
||||
} else if (data?.code !== 0 && !skipErrorNotification) {
|
||||
notification.error({
|
||||
message: `${i18n.t('message.hint')} : ${data?.code}`,
|
||||
description: data?.message,
|
||||
@@ -167,7 +168,9 @@ request.interceptors.response.use(
|
||||
return Promise.reject(error);
|
||||
}
|
||||
|
||||
errorHandler(error);
|
||||
if (!(error?.config as any)?.skipGlobalErrorNotification) {
|
||||
errorHandler(error);
|
||||
}
|
||||
return Promise.reject(error);
|
||||
},
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user