-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Description
ISSUE_NUMBER: GH-4
Description
The /update/chapternumber route in routes/chapterRoutes.js uses the POST method, which is not semantically correct for updating a resource. It should use PUT or PATCH instead.
File: repositories/QuestionBankapi/routes/chapterRoutes.js
Line: 23
Severity: medium
Current Behavior
The route uses POST to update the chapter number.
Expected Behavior
The route should use PUT or PATCH to update the chapter number.
Suggested Fix
Change the HTTP method from POST to PUT or PATCH.
Code Context
router.post("/update/chapternumber", chapterNumberUpdate)Additional Notes
Using the correct HTTP method improves the API's clarity and adherence to RESTful principles.
Reactions are currently unavailable