Merge pull request #1560 from slingamn/configerrors

fix #1559
This commit is contained in:
Shivaram Lingamneni 2021-03-01 17:10:29 -05:00 committed by GitHub
commit eeb5f9b24d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 0 deletions

View File

@ -162,6 +162,8 @@ func (ps *PersistentStatus) UnmarshalYAML(unmarshal func(interface{}) error) err
result = PersistentDisabled
}
*ps = result
} else {
err = fmt.Errorf("invalid value `%s` for server persistence status: %w", orig, err)
}
return err
}
@ -416,6 +418,8 @@ func (nr *NickEnforcementMethod) UnmarshalYAML(unmarshal func(interface{}) error
method, err := nickReservationFromString(orig)
if err == nil {
*nr = method
} else {
err = fmt.Errorf("invalid value `%s` for nick enforcement method: %w", orig, err)
}
return err
}