mirror of
https://github.com/SchildiChat/SchildiChat-android.git
synced 2024-11-21 17:05:39 +03:00
Merge pull request #4222 from abaker/fix_outgoing_conversation_notifications
Dont set person on sent message notification
This commit is contained in:
commit
7ec0872b78
2 changed files with 10 additions and 5 deletions
1
changelog.d/4221.bugfix
Normal file
1
changelog.d/4221.bugfix
Normal file
|
@ -0,0 +1 @@
|
|||
Fix conversation notification for sent messages
|
|
@ -330,11 +330,15 @@ class NotificationDrawerManager @Inject constructor(private val context: Context
|
|||
}
|
||||
roomEventGroupInfo.hasNewEvent = roomEventGroupInfo.hasNewEvent || !event.hasBeenDisplayed
|
||||
|
||||
val senderPerson = Person.Builder()
|
||||
.setName(event.senderName)
|
||||
.setIcon(iconLoader.getUserIcon(event.senderAvatarPath))
|
||||
.setKey(event.senderId)
|
||||
.build()
|
||||
val senderPerson = if (event.outGoingMessage) {
|
||||
null
|
||||
} else {
|
||||
Person.Builder()
|
||||
.setName(event.senderName)
|
||||
.setIcon(iconLoader.getUserIcon(event.senderAvatarPath))
|
||||
.setKey(event.senderId)
|
||||
.build()
|
||||
}
|
||||
|
||||
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.R) {
|
||||
val openRoomIntent = RoomDetailActivity.shortcutIntent(context, roomId)
|
||||
|
|
Loading…
Reference in a new issue