mirror of
https://github.com/labring/FastGPT.git
synced 2025-08-04 14:08:15 +00:00
4.6.7-alpha commit (#743)
Co-authored-by: Archer <545436317@qq.com> Co-authored-by: heheer <71265218+newfish-cmyk@users.noreply.github.com>
This commit is contained in:
@@ -30,10 +30,12 @@ export let simpleModeTemplates: AppSimpleEditConfigTemplateType[] = [];
|
||||
|
||||
let retryTimes = 3;
|
||||
|
||||
export const clientInitData = async (): Promise<InitDateResponse> => {
|
||||
export const clientInitData = async (): Promise<{
|
||||
feConfigs: FastGPTFeConfigsType;
|
||||
}> => {
|
||||
try {
|
||||
const res = await getSystemInitData();
|
||||
feConfigs = res.feConfigs;
|
||||
feConfigs = res.feConfigs || {};
|
||||
|
||||
chatModelList = res.chatModels ?? chatModelList;
|
||||
vectorModelList = res.vectorModels ?? vectorModelList;
|
||||
@@ -51,7 +53,9 @@ export const clientInitData = async (): Promise<InitDateResponse> => {
|
||||
systemVersion = res.systemVersion;
|
||||
simpleModeTemplates = res.simpleModeTemplates;
|
||||
|
||||
return res;
|
||||
return {
|
||||
feConfigs
|
||||
};
|
||||
} catch (error) {
|
||||
retryTimes--;
|
||||
await delay(500);
|
||||
|
Reference in New Issue
Block a user