Simplify assignment

Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
This commit is contained in:
Daniel Calviño Sánchez 2023-01-26 14:12:04 +01:00 committed by Marcel Hibbe
parent b07aaee140
commit 3efcbe2a39
No known key found for this signature in database
GPG key ID: C793F8B59F43CE7B

View file

@ -2151,13 +2151,11 @@ class ChatController(args: Bundle) :
return
}
webSocketInstance =
if (WebSocketConnectionHelper.getMagicWebSocketInstanceForUserId(conversationUser.id!!) != null) {
WebSocketConnectionHelper.getMagicWebSocketInstanceForUserId(conversationUser.id!!)
} else {
Log.d(TAG, "magicWebSocketInstance became null")
null
}
webSocketInstance = WebSocketConnectionHelper.getMagicWebSocketInstanceForUserId(conversationUser.id!!)
if (webSocketInstance == null) {
Log.d(TAG, "magicWebSocketInstance became null")
}
}
fun pullChatMessages(lookIntoFuture: Int, setReadMarker: Int = 1, xChatLastCommonRead: Int? = null) {