mirror of
https://github.com/lensapp/lens.git
synced 2025-05-20 05:10:56 +00:00
keep only items from non-loaded namespaces
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com>
This commit is contained in:
parent
819b404fc0
commit
71c2bc69d9
@ -178,10 +178,10 @@ export abstract class KubeObjectStore<T extends KubeObject = any> extends ItemSt
|
||||
|
||||
// update existing items
|
||||
if (!replace) {
|
||||
const partialIds = partialItems.map(item => item.getId());
|
||||
const namespaces = partialItems.map(item => item.getNs());
|
||||
|
||||
items = [
|
||||
...this.items.filter(existingItem => !partialIds.includes(existingItem.getId())),
|
||||
...this.items.filter(existingItem => !namespaces.includes(existingItem.getNs())),
|
||||
...partialItems,
|
||||
];
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user