From cc2a879660c324de752316e55097e00abe95b3c3 Mon Sep 17 00:00:00 2001 From: Tonis Tiigi Date: Mon, 22 Nov 2021 23:57:42 -0800 Subject: [PATCH] commands: clean up unnecessary code Signed-off-by: Tonis Tiigi --- commands/build.go | 1 - commands/util.go | 4 +--- 2 files changed, 1 insertion(+), 4 deletions(-) diff --git a/commands/build.go b/commands/build.go index 9a33bdeb..4bce23fc 100644 --- a/commands/build.go +++ b/commands/build.go @@ -393,7 +393,6 @@ func checkWarnedFlags(f *pflag.Flag) { switch t { case "flag-warn": logrus.Warn(m[0]) - break } } } diff --git a/commands/util.go b/commands/util.go index 0e19e9b2..d4ee40ad 100644 --- a/commands/util.go +++ b/commands/util.go @@ -290,9 +290,7 @@ func loadInfoData(ctx context.Context, d *dinfo) error { return errors.Wrap(err, "listing workers") } for _, w := range workers { - for _, p := range w.Platforms { - d.platforms = append(d.platforms, p) - } + d.platforms = append(d.platforms, w.Platforms...) } d.platforms = platformutil.Dedupe(d.platforms) }