Skip to content

Commit 97ba163

Browse files
committed
[refactor/#31] roomId 타입 통일
1 parent 34f6634 commit 97ba163

File tree

3 files changed

+4
-4
lines changed

3 files changed

+4
-4
lines changed

core/data/chatting/src/commonMain/kotlin/com/nexters/emotia/core/data/chatting/datasource/ChattingRemoteDataSource.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import com.nexters.emotia.network.dto.response.SendChatResponse
77
interface ChattingRemoteDataSource {
88
suspend fun createRoom(username: String): CreateRoomResponse
99
suspend fun sendChat(
10-
roomId: Int,
10+
roomId: String,
1111
message: String,
1212
): SendChatResponse
1313

core/data/chatting/src/commonMain/kotlin/com/nexters/emotia/core/data/chatting/datasource/ChattingRemoteDataSourceImpl.kt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,11 +17,11 @@ class ChattingRemoteDataSourceImpl(
1717
}
1818

1919
override suspend fun sendChat(
20-
roomId: Int,
20+
roomId: String,
2121
message: String,
2222
): SendChatResponse {
2323
return apiService.sendChat(
24-
chatRoomId = roomId.toString(),
24+
chatRoomId = roomId,
2525
message = message,
2626
)
2727
}

core/data/chatting/src/commonMain/kotlin/com/nexters/emotia/core/data/chatting/repository/ChattingRepositoryImpl.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ class ChattingRepositoryImpl(
2727

2828
override suspend fun sendChat(roomId: String, message: String): Result<ChatMessage> {
2929
return runCatching {
30-
val response = remoteDataSource.sendChat(roomId.toInt(), message)
30+
val response = remoteDataSource.sendChat(roomId, message)
3131

3232
if (!response.success) {
3333
throw IllegalStateException("API 요청 실패: ${response.error}")

0 commit comments

Comments
 (0)