Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix/return 404 entity don't exists #452

Merged
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Updated CommitteeDetails.tsx
  • Loading branch information
yashgoyal0110 authored Jan 13, 2025
commit 873a8b0a86beedf30ab3baa8d178d78284b30c4c
9 changes: 6 additions & 3 deletions frontend/src/pages/CommitteeDetails.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import { fetchAlgoliaData } from 'api/fetchAlgoliaData'
import { useEffect, useState } from 'react'
import { useParams } from 'react-router-dom'
import { getFilteredIcons, handleSocialUrls } from 'utils/utility'
import { ErrorDisplay } from 'wrappers/ErrorWrapper'
import FontAwesomeIconWrapper from 'wrappers/FontAwesomeIconWrapper'
import Card from 'components/Card'
import LoadingSpinner from 'components/LoadingSpinner'
Expand Down Expand Up @@ -32,9 +33,11 @@ const CommitteeDetailsPage = () => {

if (!committee)
return (
<div className="flex min-h-[60vh] items-center justify-center">
<p className="text-lg font-medium text-muted-foreground">No committee details found.</p>
</div>
<ErrorDisplay
statusCode={404}
title="Committee details Not Found"
message="The Committee you're looking for doesn't exist"
/>
)

const SubmitButton = {
Expand Down