diff options
author | OpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com> | 2022-08-23 11:18:02 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-08-23 11:18:02 -0400 |
commit | ee2f8155cc85705787900db71f4154d358bd419d (patch) | |
tree | 4ef8d3058658fef5d3e9740512d8aef224b1556e /cmd | |
parent | bd3bbb13493cb7a5ca71ef675b54fad307d705d5 (diff) | |
parent | 716ac1c866787d7d6b1ee8b800da527fd5b980d0 (diff) | |
download | podman-ee2f8155cc85705787900db71f4154d358bd419d.tar.gz podman-ee2f8155cc85705787900db71f4154d358bd419d.tar.bz2 podman-ee2f8155cc85705787900db71f4154d358bd419d.zip |
Merge pull request #15421 from sstosh/refactor-rawinput
Refactor: About the RawInput process
Diffstat (limited to 'cmd')
-rw-r--r-- | cmd/podman/containers/rm.go | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/cmd/podman/containers/rm.go b/cmd/podman/containers/rm.go index 1e3976389..9c760e752 100644 --- a/cmd/podman/containers/rm.go +++ b/cmd/podman/containers/rm.go @@ -149,7 +149,8 @@ func removeContainers(namesOrIDs []string, rmOptions entities.RmOptions, setExit return err } for _, r := range responses { - if r.Err != nil { + switch { + case r.Err != nil: if errors.Is(r.Err, define.ErrWillDeadlock) { logrus.Errorf("Potential deadlock detected - please run 'podman system renumber' to resolve") } @@ -160,8 +161,10 @@ func removeContainers(namesOrIDs []string, rmOptions entities.RmOptions, setExit setExitCode(r.Err) } errs = append(errs, r.Err) - } else { + case r.RawInput != "": fmt.Println(r.RawInput) + default: + fmt.Println(r.Id) } } return errs.PrintErrors() |