mirror of
https://github.com/lensapp/lens.git
synced 2025-05-20 05:10:56 +00:00
Check for accessibleNamespaces length
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com>
This commit is contained in:
parent
ca518c7f55
commit
fab7fc54b4
@ -79,8 +79,9 @@ export class ReleaseStore extends ItemStore<HelmRelease> {
|
|||||||
|
|
||||||
async loadItems(namespaces: string[]) {
|
async loadItems(namespaces: string[]) {
|
||||||
const isLoadingAll = namespaceStore.allowedNamespaces.every(ns => namespaces.includes(ns));
|
const isLoadingAll = namespaceStore.allowedNamespaces.every(ns => namespaces.includes(ns));
|
||||||
|
const noAccessibleNamespaces = namespaceStore.context.cluster.accessibleNamespaces.length === 0;
|
||||||
|
|
||||||
if (isLoadingAll) {
|
if (isLoadingAll && noAccessibleNamespaces) {
|
||||||
return helmReleasesApi.list();
|
return helmReleasesApi.list();
|
||||||
} else {
|
} else {
|
||||||
return Promise
|
return Promise
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user