Skip to content
Snippets Groups Projects
Commit 144cf399 authored by Nathanael Santoso's avatar Nathanael Santoso
Browse files

fix(course): moved insert id before course

parent 9b37a171
Branches
Tags
3 merge requests!47Final Updates,!42[Feat] [Release!] [#1] Project Release Commit,!40Fix/s4 sb 54 backend manajemen soal latihan
Pipeline #57415 passed with stage
in 1 minute and 31 seconds
......@@ -30,6 +30,7 @@ import (
// @Router /course/{id} [patch]
func (c CourseHandlerImpl) UpdateCourse(w http.ResponseWriter, r *http.Request) {
payload := course.UpdateCourseRequestPayload{}
payload.ID = chi.URLParam(r, "id")
validate := validator.New()
// Validate payload
......@@ -82,7 +83,6 @@ func (c CourseHandlerImpl) UpdateCourse(w http.ResponseWriter, r *http.Request)
}
payload.UpdateCourseToken = token[1]
payload.ID = chi.URLParam(r, "id")
err := c.CourseService.UpdateCourse(payload)
if err != nil {
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment