feat: can configure Domain field in Nextcloud OAuth provider (#3813)

This commit is contained in:
People257
2025-05-23 17:23:34 +08:00
committed by GitHub
parent 33afc52a0b
commit fed9332246
3 changed files with 15 additions and 4 deletions

View File

@ -278,9 +278,16 @@ func NewGothIdProvider(providerType string, clientId string, clientSecret string
Session: &naver.Session{},
}
case "Nextcloud":
idp = GothIdProvider{
Provider: nextcloud.New(clientId, clientSecret, redirectUrl),
Session: &nextcloud.Session{},
if hostUrl != "" {
idp = GothIdProvider{
Provider: nextcloud.NewCustomisedDNS(clientId, clientSecret, redirectUrl, hostUrl),
Session: &nextcloud.Session{},
}
} else {
idp = GothIdProvider{
Provider: nextcloud.New(clientId, clientSecret, redirectUrl),
Session: &nextcloud.Session{},
}
}
case "OneDrive":
idp = GothIdProvider{