File tree Expand file tree Collapse file tree 2 files changed +5
-5
lines changed Expand file tree Collapse file tree 2 files changed +5
-5
lines changed Original file line number Diff line number Diff line change 77 selectBug ,
88} from 'src/features/bugsPage/bugsPageSlice' ;
99import { TableBugType } from '../types' ;
10- import { EmptyState } from './components/EmptyState' ;
1110import { InfoRow } from './components/InfoRow' ;
1211import { mapBugsToTableData } from './utils/mapBugsToTableData' ;
1312import { useTableColumns } from './hooks/useTableColumns' ;
@@ -18,10 +17,6 @@ export const AllBugs = ({ bugs }: { bugs: TableBugType[] }) => {
1817 const { columns } = useTableColumns ( ) ;
1918 const dispatch = useAppDispatch ( ) ;
2019
21- if ( ! bugs . length ) {
22- return < EmptyState /> ;
23- }
24-
2520 return (
2621 < div >
2722 < InfoRow bugs = { bugs } />
Original file line number Diff line number Diff line change @@ -2,6 +2,7 @@ import { useAppSelector } from 'src/app/hooks';
22import { AllBugs } from './AllBugs' ;
33import { BugsBySeverity } from './BugsBySeverity' ;
44import { BugsByUsecase } from './BugsByUsecase' ;
5+ import { EmptyState } from './components/EmptyState' ;
56import { LoadingState } from './components/LoadingState' ;
67import { useTableData } from './hooks/useTableData' ;
78
@@ -13,6 +14,10 @@ const BugsTable = ({ campaignId }: { campaignId: number }) => {
1314 return < LoadingState /> ;
1415 }
1516
17+ if ( ! data . allBugs . length ) {
18+ return < EmptyState /> ;
19+ }
20+
1621 return (
1722 < div >
1823 { pageView === 'byUsecase' && (
You can’t perform that action at this time.
0 commit comments