mirror of
https://github.com/maelgangloff/domain-watchdog.git
synced 2025-12-29 16:15:04 +00:00
feat: auto redirect to the SSO login page
This commit is contained in:
@@ -30,7 +30,13 @@ export default function LoginPage() {
|
||||
}
|
||||
|
||||
useEffect(() => {
|
||||
getConfiguration().then(setConfiguration)
|
||||
getConfiguration().then((configuration) => {
|
||||
if(!configuration.registerEnabled && configuration.ssoLogin && configuration.ssoAutoRedirect) {
|
||||
window.location.href = '/login/oauth'
|
||||
return
|
||||
}
|
||||
setConfiguration(configuration)
|
||||
})
|
||||
}, [])
|
||||
|
||||
const grid = [
|
||||
|
||||
Reference in New Issue
Block a user