Closed Nathan-Lackie closed 2 weeks ago
Currently, when requesting a course with an ID that does not exist, an error is thrown due to no rows being returned. This should instead gracefully error, and return a 404 to the user.
https://github.com/DegreePrerequisiteTracker/Degree-Prerequisite-Tracker/blob/fa1aae716d9433621a885eba377c9980348a9bf2/src/api/courses.ts#L14-L25
Currently, when requesting a course with an ID that does not exist, an error is thrown due to no rows being returned. This should instead gracefully error, and return a 404 to the user.
https://github.com/DegreePrerequisiteTracker/Degree-Prerequisite-Tracker/blob/fa1aae716d9433621a885eba377c9980348a9bf2/src/api/courses.ts#L14-L25