irby / passwordless-authenticator-poc

Function call can be replaced with helper function CRT-A0010
Anti-pattern
Major
a year agoa year old
use strings.ReplaceAll method in strings.Replace(strings.ToLower(s), "_", ".", -1)
 37	}
 38
 39	err = k.Load(env.Provider("", ".", func(s string) string {
 40		return strings.Replace(strings.ToLower(s), "_", ".", -1) 41	}), nil)
 42	if err != nil {
 43		return nil, fmt.Errorf("failed to load config from env vars: %w", err)