mirror of
https://github.com/labring/FastGPT.git
synced 2025-07-23 13:03:50 +00:00
v4.6.4 (#585)
* perf: md format * add systemConfig schema (#2) * fix: markdown * fix: root * fix: root --------- Co-authored-by: heheer <71265218+newfish-cmyk@users.noreply.github.com>
This commit is contained in:
@@ -151,6 +151,7 @@ export async function parseHeaderCert({
|
||||
authType: AuthUserTypeEnum.root
|
||||
};
|
||||
}
|
||||
// apikey: abandon
|
||||
if (authApiKey && apikey) {
|
||||
// apikey
|
||||
const parseResult = await authOpenApiKey({ apikey });
|
||||
@@ -164,20 +165,8 @@ export async function parseHeaderCert({
|
||||
};
|
||||
}
|
||||
|
||||
return {
|
||||
uid: '',
|
||||
teamId: '',
|
||||
tmbId: '',
|
||||
appId: '',
|
||||
openApiKey: '',
|
||||
authType: AuthUserTypeEnum.token
|
||||
};
|
||||
})();
|
||||
|
||||
// not rootUser and no uid, reject request
|
||||
if (!rootkey && !uid && !teamId && !tmbId) {
|
||||
return Promise.reject(ERROR_ENUM.unAuthorization);
|
||||
}
|
||||
})();
|
||||
|
||||
return {
|
||||
userId: String(uid),
|
||||
|
Reference in New Issue
Block a user