diff options
author | Martin Czygan <martin.czygan@gmail.com> | 2021-06-01 20:36:14 +0200 |
---|---|---|
committer | Martin Czygan <martin.czygan@gmail.com> | 2021-06-01 20:36:14 +0200 |
commit | 3c100d60220810596c75abfb6257f2f675bc8c95 (patch) | |
tree | f9a9c0cc6e203311c1eedc4be735c7199b2727fb | |
parent | dad3a75961e1bca6c17cb858e32e3806a37a48f7 (diff) | |
download | refcat-3c100d60220810596c75abfb6257f2f675bc8c95.tar.gz refcat-3c100d60220810596c75abfb6257f2f675bc8c95.zip |
resolve: bail out early if possible
-rw-r--r-- | skate/cmd/skate-resolve-journal-name/main.go | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/skate/cmd/skate-resolve-journal-name/main.go b/skate/cmd/skate-resolve-journal-name/main.go index 494b236..abbfa9b 100644 --- a/skate/cmd/skate-resolve-journal-name/main.go +++ b/skate/cmd/skate-resolve-journal-name/main.go @@ -58,6 +58,10 @@ func main() { return nil, err } } + // XXX: we do not need to do any lookup w/o container name anyway. + if *keepResolvedOnly && release.ContainerName == "" { + return nil, nil + } name := strings.ToLower(release.ContainerName) results := ms.Lookup(name, -1) if len(results) != 1 { |