Open ramanxg opened 2 years ago
For queries to websoc, some courses we don't have in our cache, and this throws an error.
This is the error message:
Cannot read property 'id' of null"
Example query:
{ schedule(year:2020, quarter:"Fall", department:"COMPSCI", course_number:"275") { course { id department course_level description } } }
In schedule.helper.ts under getCourseSchedules. getCourse will sometimes return null, if it's not in our cache. If it's null, we can return what we can: id, title, department, number.
schedule.helper.ts
getCourseSchedules
getCourse
null
id
title
department
number
For queries to websoc, some courses we don't have in our cache, and this throws an error.
This is the error message:
Example query: