fix(core): Improve SAML connection test result views (#5981)
* improve test result views * refactor * lint fix
This commit is contained in:
committed by
GitHub
parent
18d5156994
commit
4c994faec1
@@ -139,14 +139,11 @@ export class SamlService {
|
||||
async handleSamlLogin(
|
||||
req: express.Request,
|
||||
binding: SamlLoginBinding,
|
||||
): Promise<
|
||||
| {
|
||||
authenticatedUser: User | undefined;
|
||||
attributes: SamlUserAttributes;
|
||||
onboardingRequired: boolean;
|
||||
}
|
||||
| undefined
|
||||
> {
|
||||
): Promise<{
|
||||
authenticatedUser: User | undefined;
|
||||
attributes: SamlUserAttributes;
|
||||
onboardingRequired: boolean;
|
||||
}> {
|
||||
const attributes = await this.getAttributesFromLoginResponse(req, binding);
|
||||
if (attributes.email) {
|
||||
const user = await Db.collections.User.findOne({
|
||||
@@ -187,7 +184,11 @@ export class SamlService {
|
||||
}
|
||||
}
|
||||
}
|
||||
return undefined;
|
||||
return {
|
||||
authenticatedUser: undefined,
|
||||
attributes,
|
||||
onboardingRequired: false,
|
||||
};
|
||||
}
|
||||
|
||||
async setSamlPreferences(prefs: SamlPreferences): Promise<SamlPreferences | undefined> {
|
||||
|
||||
Reference in New Issue
Block a user