Prevent the TimelineController from requesting a backpagination even though items are available on the TimelineProvider level. Manually populate the items subject in the TimelineProvider constructor.

This commit is contained in:
Stefan Ceriu
2023-06-29 20:13:56 +03:00
parent b89dbc3895
commit be124a972e
@@ -39,6 +39,9 @@ class RoomTimelineProvider: RoomTimelineProviderProtocol {
itemProxies = currentItems.map(TimelineItemProxy.init)
// Manually call it here as the didSet doesn't work from constructors
itemsSubject.send(itemProxies)
updatePublisher
.collect(.byTime(serialDispatchQueue, 0.1))
.sink { [weak self] in self?.updateItemsWithDiffs($0) }