mirror of
https://github.com/ichmagmaus111/ghostgram.git
synced 2026-11-03 14:17:19 +01:00
Ghostgram for iOS, rebuilt from scratch on Telegram iOS 13.0. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
21 lines
661 B
Swift
21 lines
661 B
Swift
import Foundation
|
|
import SwiftSignalKit
|
|
import Postbox
|
|
|
|
public extension TelegramEngine {
|
|
final class ItemCollections {
|
|
private let account: Account
|
|
|
|
init(account: Account) {
|
|
self.account = account
|
|
}
|
|
|
|
public func allItems(namespace: ItemCollectionId.Namespace) -> Signal<[EngineRawItemCollectionItem], NoError> {
|
|
return self.account.postbox.itemCollectionsView(orderedItemListCollectionIds: [], namespaces: [namespace], aroundIndex: nil, count: 10000000)
|
|
|> map { view -> [EngineRawItemCollectionItem] in
|
|
return view.entries.map { $0.item }
|
|
}
|
|
}
|
|
}
|
|
}
|