ListUninstalled returns all releases with Status == UNINSTALLED. An error is returned if the storage backend fails to retrieve the releases.
()
| 122 | // ListUninstalled returns all releases with Status == UNINSTALLED. An error is returned |
| 123 | // if the storage backend fails to retrieve the releases. |
| 124 | func (s *Storage) ListUninstalled() ([]release.Releaser, error) { |
| 125 | s.Logger().Debug("listing uninstalled releases in storage") |
| 126 | return s.List(func(rls release.Releaser) bool { |
| 127 | rel, err := releaserToV1Release(rls) |
| 128 | if err != nil { |
| 129 | // This will only happen if calling code does not pass the proper types. This is |
| 130 | // a problem with the application and not user data. |
| 131 | s.Logger().Error("unable to convert release to typed release", slog.Any("error", err)) |
| 132 | panic(fmt.Sprintf("unable to convert release to typed release: %s", err)) |
| 133 | } |
| 134 | return relutil.StatusFilter(common.StatusUninstalled).Check(rel) |
| 135 | }) |
| 136 | } |
| 137 | |
| 138 | // ListDeployed returns all releases with Status == DEPLOYED. An error is returned |
| 139 | // if the storage backend fails to retrieve the releases. |
nothing calls this directly
no test coverage detected