mirror of
https://github.com/lensapp/lens.git
synced 2025-05-20 05:10:56 +00:00
1 parent
386aebf98a
commit
5ef42f603e
1 file changed
+2
-4
@@ -69,14 +69,12 @@ export class KubeWatchApi {
|
||||
|
||||
@computed get apis(): string[] {
|
||||
return Array.from(this.subscribers.keys()).map(api => {
|
||||
const { cluster, namespaces, isReady } = this;
|
||||
|
||||
if (!isReady || !cluster?.isAllowedResource(api.kind)) {
|
||||
if (!this.isReady || !this.isAllowedApi(api)) {
|
||||
return [];
|
||||
}
|
||||
|
||||
if (api.isNamespaced) {
|
||||
return namespaces.map(namespace => api.getWatchUrl(namespace));
|
||||
return this.namespaces.map(namespace => api.getWatchUrl(namespace));
|
||||
} else {
|
||||
return api.getWatchUrl();
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user