Skip to content

Commit

Permalink
💚 Fix invisible TS errors
Browse files Browse the repository at this point in the history
  • Loading branch information
oliverbutler committed Feb 14, 2022
1 parent b3f0c38 commit 8a8683e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions apps/xeo-scrum/pages/api/backlog/[id]/members/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -68,8 +68,8 @@ export default async function backlogMembers(
if (req.method === 'PUT') {
const { body, error } = parseAPIRequest(req, schema);

if (error) {
return res.status(400).json({ message: error.message });
if (error || !body) {
return res.status(400).json({ message: error?.message });
}

try {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ export function Index() {
return <CentredLoader />;
}

return <Backlog backlog={data.backlog} />;
return data ? <Backlog backlog={data.backlog} /> : null;
}

export default Index;

1 comment on commit 8a8683e

@vercel
Copy link

@vercel vercel bot commented on 8a8683e Feb 14, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.