Commit 48b5c070 authored by Leonardo Aramaki's avatar Leonardo Aramaki

Fix avatar url

parent b1a6a73b
...@@ -113,6 +113,7 @@ class ChatRoomPresenter @Inject constructor(private val view: ChatRoomView, ...@@ -113,6 +113,7 @@ class ChatRoomPresenter @Inject constructor(private val view: ChatRoomView,
val message = retryIO { val message = retryIO {
if (messageId == null) { if (messageId == null) {
val username = localRepository.username() val username = localRepository.username()
println(username?.avatarUrl(username))
val newMessage = Message( val newMessage = Message(
id = id, id = id,
roomId = chatRoomId, roomId = chatRoomId,
...@@ -120,7 +121,7 @@ class ChatRoomPresenter @Inject constructor(private val view: ChatRoomView, ...@@ -120,7 +121,7 @@ class ChatRoomPresenter @Inject constructor(private val view: ChatRoomView,
timestamp = Instant.now().epochSecond, timestamp = Instant.now().epochSecond,
sender = SimpleUser(null, username, username), sender = SimpleUser(null, username, username),
attachments = null, attachments = null,
avatar = username?.avatarUrl(username), avatar = currentServer.avatarUrl(username!!),
channels = null, channels = null,
editedAt = null, editedAt = null,
editedBy = null, editedBy = null,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment