mirror of
https://github.com/podman-container-tools/podman.git
synced 2026-08-16 05:39:34 +00:00
This option causes Podman to not only remove the specified containers but all of the containers that depend on the specified containers. Fixes: https://github.com/containers/podman/issues/10360 Also ran codespell on the code Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
28 lines
498 B
Go
28 lines
498 B
Go
package reports
|
|
|
|
type RmReport struct {
|
|
Id string `json:"Id"` //nolint
|
|
Err error `json:"Err,omitempty"`
|
|
}
|
|
|
|
func RmReportsIds(r []*RmReport) []string {
|
|
ids := make([]string, 0, len(r))
|
|
for _, v := range r {
|
|
if v == nil || v.Id == "" {
|
|
continue
|
|
}
|
|
ids = append(ids, v.Id)
|
|
}
|
|
return ids
|
|
}
|
|
|
|
func RmReportsErrs(r []*RmReport) []error {
|
|
errs := make([]error, 0, len(r))
|
|
for _, v := range r {
|
|
if v == nil || v.Err == nil {
|
|
continue
|
|
}
|
|
errs = append(errs, v.Err)
|
|
}
|
|
return errs
|
|
}
|