라이브 방 조회
- 본인인증을 했더라도 19금 콘텐츠 보기를 활성화 하지 않으면 19금 라이브가 보이지 않도록 수정
This commit is contained in:
		| @@ -33,12 +33,22 @@ class LiveRoomController( | ||||
|         @RequestParam timezone: String, | ||||
|         @RequestParam dateString: String? = null, | ||||
|         @RequestParam status: LiveRoomStatus, | ||||
|         @RequestParam("isAdultContentVisible", required = false) isAdultContentVisible: Boolean? = null, | ||||
|         @AuthenticationPrincipal(expression = "#this == 'anonymousUser' ? null : member") member: Member?, | ||||
|         pageable: Pageable | ||||
|     ) = run { | ||||
|         if (member == null) throw SodaException("로그인 정보를 확인해주세요.") | ||||
|  | ||||
|         ApiResponse.ok(service.getRoomList(dateString, status, pageable, member, timezone)) | ||||
|         ApiResponse.ok( | ||||
|             service.getRoomList( | ||||
|                 dateString, | ||||
|                 status, | ||||
|                 isAdultContentVisible ?: true, | ||||
|                 pageable, | ||||
|                 member, | ||||
|                 timezone | ||||
|             ) | ||||
|         ) | ||||
|     } | ||||
|  | ||||
|     @PostMapping | ||||
|   | ||||
| @@ -113,6 +113,7 @@ class LiveRoomService( | ||||
|     fun getRoomList( | ||||
|         dateString: String?, | ||||
|         status: LiveRoomStatus, | ||||
|         isAdultContentVisible: Boolean, | ||||
|         pageable: Pageable, | ||||
|         member: Member, | ||||
|         timezone: String | ||||
| @@ -123,7 +124,7 @@ class LiveRoomService( | ||||
|                 timezone, | ||||
|                 memberId = member.id!!, | ||||
|                 isCreator = member.role == MemberRole.CREATOR, | ||||
|                 isAdult = member.auth != null | ||||
|                 isAdult = member.auth != null && isAdultContentVisible | ||||
|             ) | ||||
|         } else if (dateString != null) { | ||||
|             getLiveRoomListReservationWithDate( | ||||
| @@ -132,14 +133,14 @@ class LiveRoomService( | ||||
|                 timezone, | ||||
|                 memberId = member.id!!, | ||||
|                 isCreator = member.role == MemberRole.CREATOR, | ||||
|                 isAdult = member.auth != null | ||||
|                 isAdult = member.auth != null && isAdultContentVisible | ||||
|             ) | ||||
|         } else { | ||||
|             getLiveRoomListReservationWithoutDate( | ||||
|                 timezone, | ||||
|                 isCreator = member.role == MemberRole.CREATOR, | ||||
|                 memberId = member.id!!, | ||||
|                 isAdult = member.auth != null | ||||
|                 isAdult = member.auth != null && isAdultContentVisible | ||||
|             ) | ||||
|         } | ||||
|  | ||||
|   | ||||
		Reference in New Issue
	
	Block a user