fix(tui): scope form validators to relevant monitor types #23

Merged
lerko merged 2 commits from fix/ssl-threshold-validation into main 2026-05-24 22:03:33 +00:00
Showing only changes of commit 0a56f01929 - Show all commits
+3
View File
@@ -634,6 +634,9 @@ func (m *Model) initSiteHuhForm() tea.Cmd {
Placeholder("0"). Placeholder("0").
Value(&m.siteFormData.Retries). Value(&m.siteFormData.Retries).
Validate(func(s string) error { Validate(func(s string) error {
if m.siteFormData.SiteType == "group" {
return nil
}
v, err := strconv.Atoi(s) v, err := strconv.Atoi(s)
if err != nil { if err != nil {
return fmt.Errorf("must be a number") return fmt.Errorf("must be a number")