mirror of
https://github.com/element-hq/element-x-ios.git
synced 2025-03-10 13:37:11 +00:00
Stop adding empty groups to the gallery.
This commit is contained in:
parent
40d820d4f4
commit
681daf50ea
@ -111,8 +111,10 @@ class MediaEventsTimelineScreenViewModel: MediaEventsTimelineScreenViewModelType
|
||||
let group = MediaEventsTimelineGroup(id: item.id.uniqueID.id,
|
||||
title: titleForDate(item.timestamp),
|
||||
items: currentItems)
|
||||
currentItems = []
|
||||
newGroups.append(group)
|
||||
if !currentItems.isEmpty {
|
||||
newGroups.append(group)
|
||||
currentItems = []
|
||||
}
|
||||
} else {
|
||||
currentItems.append(item)
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user