Ensure ShortcutsHandler get all the joined rooms #4168

This commit is contained in:
Benoit Marty 2021-10-22 18:10:32 +02:00
parent 76314b9d87
commit f166348a68

View file

@ -43,13 +43,12 @@ class ShortcutsHandler @Inject constructor(
}
val session = activeSessionHolder.getSafeActiveSession() ?: return Disposables.empty()
return session
.getPagedRoomSummariesLive(
roomSummaryQueryParams {
memberships = listOf(Membership.JOIN)
},
sortOrder = RoomSortOrder.PRIORITY_AND_ACTIVITY
)
return session.getRoomSummariesLive(
roomSummaryQueryParams {
memberships = listOf(Membership.JOIN)
},
sortOrder = RoomSortOrder.PRIORITY_AND_ACTIVITY
)
.asObservable()
.subscribe { rooms ->
// Remove dead shortcuts (i.e. deleted rooms)