mirror of
https://github.com/SchildiChat/SchildiChat-android.git
synced 2025-01-24 00:01:23 +01:00
Fix #1373
This commit is contained in:
parent
ea1c75c16a
commit
8eebcef4e9
@ -22,6 +22,9 @@ package im.vector.matrix.android.api.session.user.model
|
||||
*/
|
||||
data class User(
|
||||
val userId: String,
|
||||
/**
|
||||
* For usage in UI, consider using [getBestName]
|
||||
*/
|
||||
val displayName: String? = null,
|
||||
val avatarUrl: String? = null
|
||||
) {
|
||||
|
@ -66,13 +66,13 @@ class InviteUsersToRoomViewModel @AssistedInject constructor(@Assisted
|
||||
{
|
||||
val successMessage = when (selectedUsers.size) {
|
||||
1 -> stringProvider.getString(R.string.invitation_sent_to_one_user,
|
||||
selectedUsers.first().displayName)
|
||||
selectedUsers.first().getBestName())
|
||||
2 -> stringProvider.getString(R.string.invitations_sent_to_two_users,
|
||||
selectedUsers.first().displayName,
|
||||
selectedUsers.last().displayName)
|
||||
selectedUsers.first().getBestName(),
|
||||
selectedUsers.last().getBestName())
|
||||
else -> stringProvider.getQuantityString(R.plurals.invitations_sent_to_one_and_more_users,
|
||||
selectedUsers.size - 1,
|
||||
selectedUsers.first().displayName,
|
||||
selectedUsers.first().getBestName(),
|
||||
selectedUsers.size - 1)
|
||||
}
|
||||
_viewEvents.post(InviteUsersToRoomViewEvents.Success(successMessage))
|
||||
|
Loading…
Reference in New Issue
Block a user