Explain why the UI sometimes needs to request the namespaces

Signed-off-by: Eric Promislow <epromislow@suse.com>
This commit is contained in:
Eric Promislow
2021-10-04 16:38:16 -07:00
parent 12a2917d3d
commit 5c424f2cbd

View File

@@ -47,7 +47,10 @@ export default {
);
ipcRenderer.on('images-changed', (event, images) => {
this.$data.images = images;
if (this.$data.imageNamespaces.length === 0) {
if (this.imageNamespaces.length === 0) {
// This happens if the user clicked on the Images panel before data was ready,
// so no namespaces were available when it initially asked for them.
// When the data is ready, images are pushed in, but namespaces aren't.
ipcRenderer.send('images-namespaces-read');
}
});