app/vmalert: do not pring description for all the flags on config errors

The description is too big to consume by human and it just distracts humans.
This commit is contained in:
Aliaksandr Valialkin 2020-10-08 13:34:48 +03:00
parent d8546e972a
commit d423d73251
2 changed files with 0 additions and 2 deletions

View file

@ -31,7 +31,6 @@ var (
// Init creates a Querier from provided flag values.
func Init() (Querier, error) {
if *addr == "" {
flag.PrintDefaults()
return nil, fmt.Errorf("datasource.url is empty")
}
tr, err := utils.Transport(*addr, *tlsCertFile, *tlsKeyFile, *tlsCAFile, *tlsServerName, *tlsInsecureSkipVerify)

View file

@ -26,7 +26,6 @@ var (
// Init creates a Notifier object based on provided flags.
func Init(gen AlertURLGenerator) ([]Notifier, error) {
if len(*addrs) == 0 {
flag.PrintDefaults()
return nil, fmt.Errorf("at least one `-notifier.url` must be set")
}