Skip to content

Commit 5290107

Browse files
committed
NCL-7816 Fix ServiceContainerLoading to consider empty Array DTO in 'areDataEmpty'
1 parent 0faaa69 commit 5290107

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/components/ServiceContainers/ServiceContainerLoading.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ export const ServiceContainerLoading = <T extends TServiceData>({
6767
<LoadingStateCard delayMs={loadingStateDelayMs} title={title} hasSkeleton={hasSkeleton} isInline={variant !== 'block'} />
6868
);
6969

70-
const areDataEmpty = !data || (areServiceDataPaginated(data) && !data.content.length);
70+
const areDataEmpty = !data || (areServiceDataPaginated(data) && !data.content.length) || (Array.isArray(data) && !data.length);
7171

7272
// Refresh loading: keep previous real data with loading indicator when loading new data and previous real data is available
7373
// (the component was rendered at some point before)

0 commit comments

Comments
 (0)