fix: early return causing crash

This commit is contained in:
Fredrik Burmester
2025-01-23 10:07:21 +01:00
parent 01cab2277e
commit 3e299e2136

View File

@@ -40,11 +40,10 @@ export const ScrollingCollectionList: React.FC<Props> = ({
refetchOnReconnect: true, refetchOnReconnect: true,
}); });
if (disabled || !title) return null; const { t } = useTranslation();
if (hideIfEmpty === true && data?.length === 0) return null; if (hideIfEmpty === true && data?.length === 0) return null;
if (disabled || !title) return null;
const { t } = useTranslation();
return ( return (
<View {...props}> <View {...props}>