mirror of
https://github.com/hay-kot/homebox.git
synced 2025-07-22 10:30:28 +00:00
fix failing tests
This commit is contained in:
parent
e71146df3d
commit
3cfd274212
3 changed files with 9 additions and 5 deletions
|
@ -11,7 +11,7 @@ var validate *validator.Validate
|
|||
func init() {
|
||||
validate = validator.New()
|
||||
|
||||
validate.RegisterValidation("shoutrrr", func(fl validator.FieldLevel) bool {
|
||||
err := validate.RegisterValidation("shoutrrr", func(fl validator.FieldLevel) bool {
|
||||
prefixes := [...]string{
|
||||
"discord://",
|
||||
"smtp://",
|
||||
|
@ -45,6 +45,10 @@ func init() {
|
|||
return false
|
||||
})
|
||||
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
// Checks a struct for validation errors and returns any errors the occur. This
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue