Fix focusRoomAtIndex binds

This commit is contained in:
miruka 2020-05-05 21:24:54 -04:00
parent ac0907fad7
commit 1a69ae684e

View File

@ -76,15 +76,11 @@ HListView {
}
function showAccountRoomAtIndex(index) {
const userId = model.filtered.get(
const currentUserId = model.filtered.get(
currentIndex === -1 ? 0 : currentIndex
).model.for_account
const rooms = ModelStore.get(userId, "rooms")
if (! rooms.count) return
const room = rooms.get(utils.numberWrapAt(index, rooms.count))
showRoomAtIndex(model.filteredFindIndex(room.id))
showRoomAtIndex(sectionIndice[currentUserId] + index)
}