Merge pull request #21 from benjaminbear/allow_short_usernames

allow usernames with min 3 chars
This commit is contained in:
benjaminbear 2022-05-29 15:49:37 +02:00 committed by GitHub
commit f65012480f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -14,7 +14,7 @@ type Host struct {
Ip string `form:"ip" validate:"omitempty,ipv4"`
Ttl int `form:"ttl" validate:"required,min=20,max=86400"`
LastUpdate time.Time `form:"lastupdate"`
UserName string `gorm:"unique" form:"username" validate:"min=8"`
UserName string `gorm:"unique" form:"username" validate:"min=3"`
Password string `form:"password" validate:"min=8"`
}