From d1cd709441dd6fa19b5187f039933a95b7773197 Mon Sep 17 00:00:00 2001 From: Dinika Saxena Date: Wed, 4 Oct 2023 13:53:57 +0200 Subject: [PATCH] Hotfix // Fix error when multi fetch is called with 0 resources --- src/subapps/dataExplorer/DataExplorerUtils.tsx | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/src/subapps/dataExplorer/DataExplorerUtils.tsx b/src/subapps/dataExplorer/DataExplorerUtils.tsx index 52803603e..78e1eccf7 100644 --- a/src/subapps/dataExplorer/DataExplorerUtils.tsx +++ b/src/subapps/dataExplorer/DataExplorerUtils.tsx @@ -131,10 +131,11 @@ export const fetchMultipleResources = async ( project: `${org}/${project}`, }; }); - console.log( - 'Going to multi fetch', - resourceData.map(r => r.id) - ); + + if (resourceData.length === 0) { + return []; + } + const multipleResources: NexusMultiFetchResponse = await nexus .httpPost({ path: `${apiEndpoint}/multi-fetch/resources`,