Skip to content
Snippets Groups Projects
Commit 994198f4 authored by Jaime Pérez Crespo's avatar Jaime Pérez Crespo
Browse files

Use the ID of the default auth source, not "default"

This makes it possible for existing deployments to have this working with SSO. Otherwise, the user would end up authenticated with the "default" auth source when accessing the web interface, and "another" auth source when logging in via SAML.
parent 0af69a65
No related branches found
No related tags found
No related merge requests found
......@@ -144,8 +144,18 @@ class Login
$t->data['sources'] = $this->sources;
return $t;
}
// we have a default, use that one
$as = 'default';
foreach ($this->sources as $id => $source) {
if ($id === 'default') {
continue;
}
if ($source === $this->sources['default']) {
$as = $id;
break;
}
}
}
// auth source defined, check if valid
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment