Fix issue with service.save for adding courses so that there is no chance of misusing this or accidentally creating duplicate course instances. #397
Labels
3
A more involved task likely to be somewhat complex
Server
Code on the server side of the application
Technical Debt
Code requires cleanup
The
CourseService.save
method is specifically set up to handle creating new Courses, but therepository.save
method will update a course if the data-to-be-saved includes an id. We should:CourseService.save
method to something more descriptive, e.g.CourseService.createNewCourse
.repository.save
, userepository.insert
, so that it does not update existing.The text was updated successfully, but these errors were encountered: