suda -> live
This commit is contained in:
parent
7ca71f90db
commit
aa457cc2fb
|
@ -14,7 +14,7 @@ class SodaExceptionHandler {
|
||||||
private val logger = LoggerFactory.getLogger(this::class.java)
|
private val logger = LoggerFactory.getLogger(this::class.java)
|
||||||
|
|
||||||
@ExceptionHandler(SodaException::class)
|
@ExceptionHandler(SodaException::class)
|
||||||
fun handleSudaException(e: SodaException) = run {
|
fun handleSodaException(e: SodaException) = run {
|
||||||
logger.error("API error", e)
|
logger.error("API error", e)
|
||||||
ApiResponse.error(
|
ApiResponse.error(
|
||||||
message = e.message,
|
message = e.message,
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
package kr.co.vividnext.sodalive.live.room
|
package kr.co.vividnext.sodalive.live.room
|
||||||
|
|
||||||
data class CreateSudaRoomRequest(
|
data class CreateLiveRoomRequest(
|
||||||
val title: String,
|
val title: String,
|
||||||
val content: String,
|
val content: String,
|
||||||
val coverImageUrl: String? = null,
|
val coverImageUrl: String? = null,
|
|
@ -161,7 +161,7 @@ class LiveRoomService(
|
||||||
|
|
||||||
@Transactional
|
@Transactional
|
||||||
fun createLiveRoom(coverImage: MultipartFile?, requestString: String, member: Member): CreateLiveRoomResponse {
|
fun createLiveRoom(coverImage: MultipartFile?, requestString: String, member: Member): CreateLiveRoomResponse {
|
||||||
val request = objectMapper.readValue(requestString, CreateSudaRoomRequest::class.java)
|
val request = objectMapper.readValue(requestString, CreateLiveRoomRequest::class.java)
|
||||||
if (request.coverImageUrl == null && coverImage == null) {
|
if (request.coverImageUrl == null && coverImage == null) {
|
||||||
throw SodaException("커버이미지를 선택해 주세요.")
|
throw SodaException("커버이미지를 선택해 주세요.")
|
||||||
}
|
}
|
||||||
|
@ -604,7 +604,7 @@ class LiveRoomService(
|
||||||
val coverImagePath = s3Uploader.upload(
|
val coverImagePath = s3Uploader.upload(
|
||||||
inputStream = coverImage.inputStream,
|
inputStream = coverImage.inputStream,
|
||||||
bucket = coverImageBucket,
|
bucket = coverImageBucket,
|
||||||
filePath = "suda_room_cover/${room.id}/$coverImageFileName",
|
filePath = "live_room_cover/${room.id}/$coverImageFileName",
|
||||||
metadata = metadata
|
metadata = metadata
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue