From e1c82b1246a4a4d42a46beba1982cb4ed3ff0555 Mon Sep 17 00:00:00 2001 From: Radoslaw Szwajkowski Date: Fri, 8 Sep 2023 16:08:02 +0200 Subject: [PATCH] Add isArray() check for received inventory data Signed-off-by: Radoslaw Szwajkowski --- .../VirtualMachines/components/ProviderVirtualMachinesList.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/forklift-console-plugin/src/modules/Providers/views/details/tabs/VirtualMachines/components/ProviderVirtualMachinesList.tsx b/packages/forklift-console-plugin/src/modules/Providers/views/details/tabs/VirtualMachines/components/ProviderVirtualMachinesList.tsx index b3abc782f..89873b365 100644 --- a/packages/forklift-console-plugin/src/modules/Providers/views/details/tabs/VirtualMachines/components/ProviderVirtualMachinesList.tsx +++ b/packages/forklift-console-plugin/src/modules/Providers/views/details/tabs/VirtualMachines/components/ProviderVirtualMachinesList.tsx @@ -60,7 +60,7 @@ export const ProviderVirtualMachinesList: React.FC(inventoryOptions); const vmData: VmData[] = - !loading && !error && vms + !loading && !error && Array.isArray(vms) ? vms.map((vm) => ({ vm, name: vm.name,