From 60f9ca6fee7040483bc3ad561504be803d8662e5 Mon Sep 17 00:00:00 2001 From: Geoff Bourne Date: Sat, 21 Mar 2020 13:36:53 -0500 Subject: [PATCH] Allowed for bedrock-only prometheus exporter config --- prom_cmd.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/prom_cmd.go b/prom_cmd.go index cc84b27..1e41b29 100644 --- a/prom_cmd.go +++ b/prom_cmd.go @@ -43,7 +43,7 @@ func (c *exportPrometheusCmd) SetFlags(f *flag.FlagSet) { } func (c *exportPrometheusCmd) Execute(_ context.Context, _ *flag.FlagSet, args ...interface{}) subcommands.ExitStatus { - if len(c.Servers) == 0 { + if (len(c.Servers) + len(c.BedrockServers)) == 0 { printUsageError("requires at least one server") return subcommands.ExitUsageError }