Auth: Hide forgot password if grafana auth is disabled (#79895)

* hide forgot password if grafana auth is disabled

* fix test
This commit is contained in:
Jo
2024-01-04 10:46:55 +01:00
committed by GitHub
parent e924627659
commit 5ae3249c36
6 changed files with 19 additions and 9 deletions
+1 -1
View File
@@ -551,7 +551,7 @@ type Cfg struct {
// AddChangePasswordLink returns if login form is disabled or not since
// the same intention can be used to hide both features.
func (cfg *Cfg) AddChangePasswordLink() bool {
return !cfg.DisableLoginForm
return !(cfg.DisableLoginForm || cfg.DisableLogin)
}
type CommandLineArgs struct {