Skip to content

Commit

Permalink
Do not use m.room.aliases event to compute a room name (#2428)
Browse files Browse the repository at this point in the history
  • Loading branch information
bmarty committed Nov 30, 2020
1 parent 4d9b9cb commit 03715e0
Showing 1 changed file with 0 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -71,12 +71,6 @@ internal class RoomDisplayNameResolver @Inject constructor(
return name
}

val aliases = CurrentStateEventEntity.getOrNull(realm, roomId, type = EventType.STATE_ROOM_ALIASES, stateKey = "")?.root
name = ContentMapper.map(aliases?.content).toModel<RoomAliasesContent>()?.aliases?.firstOrNull()
if (!name.isNullOrEmpty()) {
return name
}

val roomMembers = RoomMemberHelper(realm, roomId)
val activeMembers = roomMembers.queryActiveRoomMembersEvent().findAll()

Expand Down

0 comments on commit 03715e0

Please sign in to comment.