fix: recognize ldap as a username provider

This commit is contained in:
Stavros
2025-07-05 03:02:37 +03:00
parent e55f29ccf9
commit 3fe17cb4ec
2 changed files with 3 additions and 3 deletions

View File

@@ -162,9 +162,9 @@ export const LoginPage = () => {
/>
)}
{configuredProviders.length == 0 && (
<h3 className="text-center text-xl text-red-600">
<p className="text-center text-red-600 max-w-sm">
{t("failedToFetchProvidersTitle")}
</h3>
</p>
)}
</CardContent>
</Card>

View File

@@ -352,7 +352,7 @@ func (auth *Auth) GetSessionCookie(c *gin.Context) (types.SessionCookie, error)
func (auth *Auth) UserAuthConfigured() bool {
// If there are users, return true
return len(auth.Config.Users) > 0
return len(auth.Config.Users) > 0 || auth.LDAP != nil
}
func (auth *Auth) ResourceAllowed(c *gin.Context, context types.UserContext, labels types.Labels) bool {