chore: corrected misleading error descriptions, removed redundant comments

This commit is contained in:
2025-06-24 01:11:49 +03:00
parent e5d245519a
commit cfe60cfb8e

View File

@@ -45,7 +45,7 @@ func ValidatePassword(password string) error {
if cfg.PasswordCheckCases { if cfg.PasswordCheckCases {
differentCasesPresent := regexp.MustCompile(`(?=.*[a-z])(?=.*[A-Z])`).MatchString(password); if !differentCasesPresent { differentCasesPresent := regexp.MustCompile(`(?=.*[a-z])(?=.*[A-Z])`).MatchString(password); if !differentCasesPresent {
return errors.New("Password must contain at least 1 number") return errors.New("Password must have uppercase and lowercase characters")
} }
} }