Skip to content

Commit adcbfad

Browse files
authored
Merge branch 'develop' into refactor/IDLE-000
2 parents 4631d07 + 01151a2 commit adcbfad

File tree

2 files changed

+1
-5
lines changed

2 files changed

+1
-5
lines changed

core/data/src/main/java/com/idle/data/repository/ChatRepositoryImpl.kt

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,6 @@ class ChatRepositoryImpl @Inject constructor(
7575
myId = myId,
7676
lastMessageId = messageId
7777
)
78-
7978
override suspend fun getChatRoomMessages(
8079
userType: UserType,
8180
roomId: String,
@@ -152,7 +151,6 @@ class ChatRepositoryImpl @Inject constructor(
152151
return chatDataSource.subscribeChatMessage(userId)
153152
.map { response ->
154153
val message = response.toVO()
155-
156154
when (message) {
157155
is ChatMessage -> {
158156
// 만약 채팅 메시지를 수신했다면,
@@ -176,7 +174,6 @@ class ChatRepositoryImpl @Inject constructor(
176174
// 로컬에 해당 메시지를 저장
177175
localChatDataSource.insertMessage(message, userId)
178176
}
179-
180177
is ReadMessage -> {
181178
// 상대방이 읽었다는 메시지를 수신했다면,
182179
if (message.opponentId != userId) {

core/network/src/main/java/com/idle/network/source/ChatDataSource.kt

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
package com.idle.network.source
22

33
import com.idle.domain.model.auth.UserType
4-
import com.idle.network.BuildConfig
54
import com.idle.network.api.ChatApi
65
import com.idle.network.di.TokenManager
76
import com.idle.network.model.chat.ChatResponse
@@ -93,7 +92,7 @@ class ChatDataSource @Inject constructor(
9392

9493
suspend fun subscribeChatMessage(userId: String): Flow<ChatResponse> =
9594
session?.subscribe(
96-
StompSubscribeHeaders(destination = "/sub/${userId}"),
95+
StompSubscribeHeaders(destination = "/sub/${'$'}{userId}"),
9796
chatResponseSerializer,
9897
) ?: flow { throw IOException("웹소켓을 먼저 연결해주세요.") }
9998

0 commit comments

Comments
 (0)