fixes erroneous render

This commit is contained in:
Alex Corey
2020-07-16 12:59:27 -04:00
parent ad536ec3d9
commit 496862592a

View File

@@ -167,10 +167,8 @@ function SurveyList({
</AlertModal>
);
}
if (!questions || questions?.length <= 0) {
return (
<>
{(!questions || questions?.length <= 0) && (
<EmptyState variant="full">
<EmptyStateIcon icon={CubesIcon} />
<Title size="lg" headingLevel="h3">
@@ -181,7 +179,10 @@ function SurveyList({
</EmptyStateBody>
<ToolbarAddButton isDisabled={!canEdit} linkTo={`${match.url}/add`} />
</EmptyState>
)}
);
}
return (
<>
<SurveyToolbar
isAllSelected={isAllSelected}
onSelectAll={handleSelectAll}