Skip to content

Commit

Permalink
Merge branch 'master' of https://github.com/Netflix/metaflow-ui
Browse files Browse the repository at this point in the history
  • Loading branch information
obgibson committed Aug 2, 2023
2 parents 89a659e + 51e8a0f commit e1e3f51
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions src/components/MFCard/useTaskCards.ts
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,15 @@ export default function useTaskCards(task: Task | null, decorators: Decorator[])
status: result.data.length >= expectedCards.length ? 'success' : prev[path]?.status,
},
}));
} else {
// The request returned a 500 because there are no cards for this task
setTaskCards((prev) => ({
...prev,
[path]: {
cards: prev[path]?.cards ?? [],
status: result.status === 500 ? 'success' : 'error',
},
}));
}
})
.catch((e) => {
Expand Down

0 comments on commit e1e3f51

Please sign in to comment.