diff --git a/ui/components/Page.tsx b/ui/components/Page.tsx index 8cf271d336..033a5f4da8 100644 --- a/ui/components/Page.tsx +++ b/ui/components/Page.tsx @@ -7,7 +7,6 @@ import Alert from "./Alert"; import Breadcrumbs, { Breadcrumb } from "./Breadcrumbs"; import Flex from "./Flex"; import LoadingPage from "./LoadingPage"; -import Spacer from "./Spacer"; import UserSettings from "./UserSettings"; export type PageProps = { @@ -59,17 +58,15 @@ const TopToolBar = styled(Flex)` `; export function Errors({ error }) { - const arr = _.isArray(error) ? error : [error]; + const arr = _.isArray(error) ? _.uniqBy(error, (e) => e?.message) : [error]; if (arr[0]) return ( - - + {_.map(arr, (e, i) => ( ))} - ); return null;