Refactoring

This commit is contained in:
Ali
2021-09-07 13:09:06 +04:00
parent f0f02dc4b9
commit 1141e09c1b
257 changed files with 1894 additions and 1720 deletions

View File

@@ -115,8 +115,6 @@ private func synchronizePinnedChats(transaction: Transaction, postbox: Postbox,
switch item {
case let .peer(peerId):
return peerId.namespace != Namespaces.Peer.SecretChat
default:
return true
}
}
let localItemIds = transaction.getPinnedItemIds(groupId: groupId)
@@ -124,8 +122,6 @@ private func synchronizePinnedChats(transaction: Transaction, postbox: Postbox,
switch item {
case let .peer(peerId):
return peerId.namespace != Namespaces.Peer.SecretChat
default:
return true
}
}
@@ -167,7 +163,7 @@ private func synchronizePinnedChats(transaction: Transaction, postbox: Postbox,
var apiChannelPts: Int32?
let apiNotificationSettings: Api.PeerNotifySettings
switch dialog {
case let .dialog(flags, peer, topMessage, readInboxMaxId, readOutboxMaxId, unreadCount, unreadMentionsCount, peerNotificationSettings, pts, _, _):
case let .dialog(flags, peer, topMessage, readInboxMaxId, readOutboxMaxId, unreadCount, _, peerNotificationSettings, pts, _, _):
apiPeer = peer
apiTopMessage = topMessage
apiReadInboxMaxId = readInboxMaxId