Skip to content

Commit

Permalink
debug/add-null-support-so-log-page-doesnt-crash-when-event-not-found
Browse files Browse the repository at this point in the history
Make sure log page still displays when event not found(happens when we refresh db and insert fake data
  • Loading branch information
DavidHuang2002 committed Apr 29, 2024
1 parent 92a509d commit 8cd7895
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion components/Logs/LogsDashboard.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ const processLogDataForTable = (
return logData.map(log => {
return {
...log,
eventName: log.event.name,
eventName: log.event?.name,
};
});
};
Expand Down
2 changes: 1 addition & 1 deletion components/Logs/LogsTable.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ export default function LogsTable({ logData }: { logData: LogTableData[] }) {
key: 'seeEvent',
render: (event: any) => {
return (
<Link href={`/event/${event._id}`}>
<Link href={`/event/${event?._id}`}>
{/* light blue color text */}
<div style={{ color: '#1890ff' }}>
<LinkOutlined /> See event
Expand Down

0 comments on commit 8cd7895

Please sign in to comment.