diff --git a/src/components/view/Course.jsx b/src/components/view/Course.jsx index 5e4f46a..fe2a7bf 100644 --- a/src/components/view/Course.jsx +++ b/src/components/view/Course.jsx @@ -7,9 +7,9 @@ import { normalizeCourseName, WEEK_DAYS } from '../../utils.jsx' export const Course = ({ events, selection, setSelection, hideOtherCourses }) => { const selectionSet = new Set(selection) - const visibleEvents = !hideOtherCourses ? events : events.filter(e => selectionSet.has(e.name)) + const visibleEvents = !hideOtherCourses ? events : events.filter(e => selectionSet.has(e.id)) - const eventsByCourse = _.groupBy(_.sortBy(visibleEvents, 'name'), 'name') + const eventsByCourse = _.groupBy(_.sortBy(visibleEvents, 'id'), 'id') const [currentlyHovered, setCurrentlyHovered] = useState(null) const element = useRef() @@ -38,20 +38,20 @@ export const Course = ({ events, selection, setSelection, hideOtherCourses }) => return (