시리즈 콘텐츠 제거
- removeIf를 이용하여 콘텐츠를 제거했지만 제거되지 않던 버그 수정
This commit is contained in:
		| @@ -253,7 +253,6 @@ class CreatorAdminContentSeriesService( | ||||
|         val series = repository.findByIdAndCreatorId(id = request.seriesId, creatorId = memberId) | ||||
|             ?: throw SodaException("잘못된 접근입니다.") | ||||
|  | ||||
|         val removeContentList = series.contentList.filter { it.content!!.id == request.contentId } | ||||
|         series.contentList.removeAll(removeContentList) | ||||
|         series.contentList.removeIf { it.content!!.id == request.contentId } | ||||
|     } | ||||
| } | ||||
|   | ||||
| @@ -51,10 +51,10 @@ data class Series( | ||||
|  | ||||
|     var coverImage: String? = null | ||||
|  | ||||
|     @OneToMany(mappedBy = "series", cascade = [CascadeType.ALL]) | ||||
|     @OneToMany(mappedBy = "series", cascade = [CascadeType.ALL], orphanRemoval = true) | ||||
|     var contentList: MutableList<SeriesContent> = mutableListOf() | ||||
|  | ||||
|     @OneToMany(mappedBy = "series", cascade = [CascadeType.ALL]) | ||||
|     @OneToMany(mappedBy = "series", cascade = [CascadeType.ALL], orphanRemoval = true) | ||||
|     var keywordList: MutableList<SeriesKeyword> = mutableListOf() | ||||
|  | ||||
|     fun toDetailResponse(imageHost: String): GetCreatorAdminContentSeriesDetailResponse { | ||||
|   | ||||
		Reference in New Issue
	
	Block a user