diff --git a/cmpserver/plugin/config.go b/cmpserver/plugin/config.go index c772abb7f7..faa718ff9f 100644 --- a/cmpserver/plugin/config.go +++ b/cmpserver/plugin/config.go @@ -37,7 +37,7 @@ type Discover struct { } func (d Discover) IsDefined() bool { - return d.FileName != "" || d.Find.Glob == "" || len(d.Find.Command.Command) > 0 + return d.FileName != "" || d.Find.Glob != "" || len(d.Find.Command.Command) > 0 } // Command holds binary path and arguments list diff --git a/cmpserver/plugin/plugin.go b/cmpserver/plugin/plugin.go index 379616260c..08be235315 100644 --- a/cmpserver/plugin/plugin.go +++ b/cmpserver/plugin/plugin.go @@ -113,7 +113,7 @@ func runCommand(ctx context.Context, command Command, path string, env []string) } if len(output) == 0 { log.WithFields(log.Fields{ - "stderr": stderr, + "stderr": stderr.String(), "command": command, }).Warn("Plugin command returned zero output") }