aboutsummaryrefslogtreecommitdiffstats
path: root/webui/src/pages/bug/BugQuery.tsx
diff options
context:
space:
mode:
authorMichael Muré <batolettre@gmail.com>2021-03-29 10:58:10 +0200
committerMichael Muré <batolettre@gmail.com>2021-03-29 11:02:08 +0200
commitaa0449a3eafa42c8c0d44bbdc2b79c5f47bd2d32 (patch)
treecd0c72a0229bb38cf8096ce198384cdd972f66e2 /webui/src/pages/bug/BugQuery.tsx
parent5215634d0dca37c545904fbc8a12ddd9b8eb72df (diff)
parente985653701e8438e27ee5f925fd0aa7c0eef09fe (diff)
downloadgit-bug-aa0449a3eafa42c8c0d44bbdc2b79c5f47bd2d32.tar.gz
Merge remote-tracking branch 'origin/master' into dag-entity
Diffstat (limited to 'webui/src/pages/bug/BugQuery.tsx')
-rw-r--r--webui/src/pages/bug/BugQuery.tsx4
1 files changed, 3 insertions, 1 deletions
diff --git a/webui/src/pages/bug/BugQuery.tsx b/webui/src/pages/bug/BugQuery.tsx
index 2a70a2f8..5d459c42 100644
--- a/webui/src/pages/bug/BugQuery.tsx
+++ b/webui/src/pages/bug/BugQuery.tsx
@@ -3,6 +3,8 @@ import { RouteComponentProps } from 'react-router-dom';
import CircularProgress from '@material-ui/core/CircularProgress';
+import NotFoundPage from '../notfound/NotFoundPage';
+
import Bug from './Bug';
import { useGetBugQuery } from './BugQuery.generated';
@@ -15,8 +17,8 @@ const BugQuery: React.FC<Props> = ({ match }: Props) => {
variables: { id: match.params.id },
});
if (loading) return <CircularProgress />;
+ if (!data?.repository?.bug) return <NotFoundPage />;
if (error) return <p>Error: {error}</p>;
- if (!data?.repository?.bug) return <p>404.</p>;
return <Bug bug={data.repository.bug} />;
};