diff --git a/apps/antalmanac/src/components/RightPane/CoursePane/CourseRenderPane.tsx b/apps/antalmanac/src/components/RightPane/CoursePane/CourseRenderPane.tsx index c812b3d18..f2efc9c49 100644 --- a/apps/antalmanac/src/components/RightPane/CoursePane/CourseRenderPane.tsx +++ b/apps/antalmanac/src/components/RightPane/CoursePane/CourseRenderPane.tsx @@ -18,6 +18,7 @@ import AppStore from '$stores/AppStore'; import { isDarkMode, queryWebsoc, queryWebsocMultiple } from '$lib/helpers'; import Grades from '$lib/grades'; import analyticsEnum from '$lib/analytics'; +import { openSnackbar } from '$actions/AppStoreActions'; function flattenSOCObject(SOCObject: WebsocAPIResponse): (WebsocSchool | WebsocDepartment | AACourse)[] { const courseColors = AppStore.getAddedCourses().reduce((accumulator, { section }) => { @@ -40,7 +41,7 @@ function flattenSOCObject(SOCObject: WebsocAPIResponse): (WebsocSchool | WebsocD return accumulator; }, []); -}; +} const RecruitmentBanner = () => { const [bannerVisibility, setBannerVisibility] = React.useState(true); @@ -195,7 +196,9 @@ export function CourseRenderPane() { setError(false); setCourseData(flattenSOCObject(websocJsonResp)); } catch (error) { + console.error(error); setError(true); + openSnackbar('error', 'We ran into an error while looking up class info'); } finally { setLoading(false); }