mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-12-23 22:55:00 +00:00
Fix ItemListController crash?
This commit is contained in:
@@ -146,7 +146,8 @@ private enum SelectivePrivacyPeersEntry: ItemListNodeEntry {
|
||||
}
|
||||
}
|
||||
|
||||
func item(_ arguments: SelectivePrivacyPeersControllerArguments) -> ListViewItem {
|
||||
func item(_ arguments: Any) -> ListViewItem {
|
||||
let arguments = arguments as! SelectivePrivacyPeersControllerArguments
|
||||
switch self {
|
||||
case let .peerItem(_, theme, strings, dateTimeFormat, nameDisplayOrder, peer, editing, enabled):
|
||||
var text: ItemListPeerItemText = .none
|
||||
@@ -349,7 +350,7 @@ public func selectivePrivacyPeersController(context: AccountContext, title: Stri
|
||||
|
||||
let signal = combineLatest(context.sharedContext.presentationData, statePromise.get(), peersPromise.get())
|
||||
|> deliverOnMainQueue
|
||||
|> map { presentationData, state, peers -> (ItemListControllerState, (ItemListNodeState<SelectivePrivacyPeersEntry>, SelectivePrivacyPeersEntry.ItemGenerationArguments)) in
|
||||
|> map { presentationData, state, peers -> (ItemListControllerState, (ItemListNodeState, Any)) in
|
||||
var rightNavigationButton: ItemListNavigationButton?
|
||||
if !peers.isEmpty {
|
||||
if state.editing {
|
||||
|
||||
Reference in New Issue
Block a user