Skip to content

Commit

Permalink
Merge pull request #7748 from rawagner/dv_optional
Browse files Browse the repository at this point in the history
Bug 1913560: Make DataVolumes and DV pods optional when fetching base images
  • Loading branch information
openshift-merge-robot committed Jan 7, 2021
2 parents 1c4ca45 + 7d57788 commit 644e302
Showing 1 changed file with 4 additions and 2 deletions.
Expand Up @@ -75,8 +75,10 @@ export const useBaseImages = (
const dvValues = Object.values(dvs);
const podValues = Object.values(pods);

const loaded = [...pvcValues, ...dvValues, ...podValues].every((value) => value.loaded);
const loadError = [...pvcValues, ...dvValues, ...podValues].find((value) => value.loadError);
const loaded = [...pvcValues, ...dvValues, ...podValues].every(
(value) => value.loaded || !!value.loadError,
);
const loadError = pvcValues.find((value) => value.loadError);
const pvcData = pvcValues.reduce<PersistentVolumeClaimKind[]>(
(acc, pvc) => acc.concat(pvc.data),
[],
Expand Down

0 comments on commit 644e302

Please sign in to comment.