config/auth.go
func (c *AuthConfig) Finalize() {
	if c.Enabled == nil {
		c.Enabled = Bool(false ||
			StringPresent(c.Username) ||
			StringPresent(c.Password))
	}
	if c.Username == nil {
		c.Username = String("")
	}

	if c.Password == nil {
		c.Password = String("")
	}

	if c.Enabled == nil {
		c.Enabled = Bool(*c.Username != "" || *c.Password != "")
	}
}
func (c *AuthConfig) Finalize() {
	if c.Enabled == nil {
		c.Enabled = Bool(false ||
			StringPresent(c.Username) ||
			StringPresent(c.Password))
	}
	if c.Username == nil {
		c.Username = String("")
	}

	if c.Password == nil {
		c.Password = String("")
	}

	if c.Enabled == nil {
		c.Enabled = Bool(*c.Username != "" || *c.Password != "")
	}
}
func ( c * AuthConfig ) Finalize ( ) { if c . Enabled == nil { c . Enabled = Bool ( false || StringPresent ( c . Username ) || StringPresent ( c . Password ) ) } if c . Username == nil { c . Username = String ( " " ) } if c . Password == nil { c . Password = String ( " " ) } if c . Enabled == nil { c . Enabled = Bool ( * c . Username != " " || * c . Password != " " ) } }
// Finalize ensures there no nil pointers.
Finalize ensures there no nil pointers .