feat: remove published status check when deleting lessons
Remove validation that prevented deletion of published lessons. Lessons can now be deleted regardless of their published status without requiring unpublishing first.
This commit is contained in:
parent
b7e4f45942
commit
7ac1a5af0a
1 changed files with 0 additions and 5 deletions
|
|
@ -565,11 +565,6 @@ export class ChaptersLessonService {
|
|||
|
||||
if (!lesson) throw new NotFoundError('Lesson not found');
|
||||
|
||||
// Check if lesson is published
|
||||
if (lesson.is_published) {
|
||||
throw new ValidationError('Cannot delete published lesson. Please unpublish first.');
|
||||
}
|
||||
|
||||
// Delete attachment files from MinIO
|
||||
if (lesson.attachments && lesson.attachments.length > 0) {
|
||||
for (const attachment of lesson.attachments) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue