allowing null users in the email search, fixes missing indentity server helpers when inviting by email
This commit is contained in:
parent
f2c22c1985
commit
c90dbf2f38
|
@ -177,11 +177,9 @@ class UserListViewModel @AssistedInject constructor(@Assisted initialState: User
|
||||||
private suspend fun executeSearchEmail(search: String) {
|
private suspend fun executeSearchEmail(search: String) {
|
||||||
suspend {
|
suspend {
|
||||||
val params = listOf(ThreePid.Email(search))
|
val params = listOf(ThreePid.Email(search))
|
||||||
val foundThreePid = tryOrNull {
|
val foundThreePid = session.identityService().lookUp(params).firstOrNull()
|
||||||
session.identityService().lookUp(params).firstOrNull()
|
|
||||||
}
|
|
||||||
if (foundThreePid == null) {
|
if (foundThreePid == null) {
|
||||||
null
|
ThreePidUser(email = search, user = null)
|
||||||
} else {
|
} else {
|
||||||
try {
|
try {
|
||||||
val json = session.getProfile(foundThreePid.matrixId)
|
val json = session.getProfile(foundThreePid.matrixId)
|
||||||
|
|
Loading…
Reference in New Issue