You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
. Add DELETE /api/v1/admin/courses/:id/modules/:moduleId with cascade #329
What: Ensure that deleting a course module also cleans up associated quizzes and submissions.
Why: When an admin removes a module from a course, orphaned quiz records and submissions remain in the database, causing data inconsistency.
Scope: In the module deletion logic, delete all quizzes for the module and their submissions. Use database transaction to ensure atomicity. Log the cleanup action.
Congratulations, @davidishere1! 🎉 Your application was accepted by the repo's maintainers, and the issue is due on August 31, 2026.
🧑💻 @davidishere1: Please resolve the issue such that the repo's maintainers have enough time to review your contribution before the due date. You'll earn Points for completing the issue on-time, which will make you eligible for a share of the Stellar Wave Program's reward pool.
Warning
When opening a PR, please link it to this issue to ensure it gets tracked accurately. Points are awarded when this issue is marked as completed by the maintainer.
🤠 Repo maintainers: Please keep an eye on the contributor's progress and review their work before the due date. You can manage this issue, including adjusting its complexity and points, here.
Already fully implemented and correct: `CourseService.deleteModule` (`src/modules/courses/course.service.ts`) runs in a DB transaction, deletes the module's quizzes, relies on the existing `quiz_submissions.quiz_id` foreign key's `ON DELETE CASCADE` to clean up submissions, and calls `auditLog("course.module.deleted", ...)`. The route already matches what's asked for: `DELETE /api/v1/admin/courses/:id/modules/:moduleId`.
Not raising a PR for it specifically — it's correct as-is, just currently unbuildable because it lives in `course.service.ts`, which has unrelated breakage from a bad merge (PR #450, see #455 for the two syntax errors I did fix from that). Once that file's other issues (missing `courseShares`/`courseReviews` schema exports, missing controller methods) are sorted out, this should just work.
Activity
timilehin01010-byte commentedon Aug 31, 2026
@timilehin01010-byte has applied to work on this issue as part of the Stellar Wave Program's 8th wave.
ℹ️ Repo Maintainers: To accept this application, review their application or assign @timilehin01010-byte to this issue.
vijay11149 commentedon Aug 31, 2026
@vijay11149 has applied to work on this issue as part of the Stellar Wave Program's 8th wave.
ℹ️ Repo Maintainers: To accept this application, review their application or assign @vijay11149 to this issue.
poaspergillus commentedon Aug 31, 2026
@poaspergillus has applied to work on this issue as part of the Stellar Wave Program's 8th wave.
ℹ️ Repo Maintainers: To accept this application, review their application or assign @poaspergillus to this issue.
davidishere1 commentedon Aug 31, 2026
@davidishere1 has applied to work on this issue as part of the Stellar Wave Program's 8th wave.
ℹ️ Repo Maintainers: To accept this application, review their application or assign @davidishere1 to this issue.
drips-wave commentedon Aug 31, 2026
Congratulations, @davidishere1! 🎉 Your application was accepted by the repo's maintainers, and the issue is due on August 31, 2026.
🧑💻 @davidishere1: Please resolve the issue such that the repo's maintainers have enough time to review your contribution before the due date. You'll earn Points for completing the issue on-time, which will make you eligible for a share of the Stellar Wave Program's reward pool.
Warning
When opening a PR, please link it to this issue to ensure it gets tracked accurately. Points are awarded when this issue is marked as completed by the maintainer.
🤠 Repo maintainers: Please keep an eye on the contributor's progress and review their work before the due date. You can manage this issue, including adjusting its complexity and points, here.
🌊 Happy Wave 🌊
davidishere1 commentedon Sep 1, 2026
Already fully implemented and correct: `CourseService.deleteModule` (`src/modules/courses/course.service.ts`) runs in a DB transaction, deletes the module's quizzes, relies on the existing `quiz_submissions.quiz_id` foreign key's `ON DELETE CASCADE` to clean up submissions, and calls `auditLog("course.module.deleted", ...)`. The route already matches what's asked for: `DELETE /api/v1/admin/courses/:id/modules/:moduleId`.
Not raising a PR for it specifically — it's correct as-is, just currently unbuildable because it lives in `course.service.ts`, which has unrelated breakage from a bad merge (PR #450, see #455 for the two syntax errors I did fix from that). Once that file's other issues (missing `courseShares`/`courseReviews` schema exports, missing controller methods) are sorted out, this should just work.