mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-09-02 18:59:51 +00:00
fixed updating autoremoveTimeout for basic groups
This commit is contained in:
parent
698763fc05
commit
a4d4dd8f11
@ -291,7 +291,7 @@ func _internal_fetchAndUpdateCachedPeerData(accountPeerId: PeerId, peerId rawPee
|
||||
}
|
||||
|
||||
switch fullChat {
|
||||
case let .chatFull(chatFullFlags, _, chatFullAbout, chatFullParticipants, chatFullChatPhoto, _, chatFullExportedInvite, chatFullBotInfo, chatFullPinnedMsgId, _, chatFullCall, _, chatFullGroupcallDefaultJoinAs, chatFullThemeEmoticon, chatFullRequestsPending, _, allowedReactions):
|
||||
case let .chatFull(chatFullFlags, _, chatFullAbout, chatFullParticipants, chatFullChatPhoto, _, chatFullExportedInvite, chatFullBotInfo, chatFullPinnedMsgId, _, chatFullCall, chatTtlPeriod, chatFullGroupcallDefaultJoinAs, chatFullThemeEmoticon, chatFullRequestsPending, _, allowedReactions):
|
||||
var botInfos: [CachedPeerBotInfo] = []
|
||||
for botInfo in chatFullBotInfo ?? [] {
|
||||
switch botInfo {
|
||||
@ -305,6 +305,9 @@ func _internal_fetchAndUpdateCachedPeerData(accountPeerId: PeerId, peerId rawPee
|
||||
}
|
||||
let participants = CachedGroupParticipants(apiParticipants: chatFullParticipants)
|
||||
|
||||
let autoremoveTimeout: CachedPeerAutoremoveTimeout = .known(CachedPeerAutoremoveTimeout.Value(chatTtlPeriod))
|
||||
|
||||
|
||||
var invitedBy: PeerId?
|
||||
if let participants = participants {
|
||||
for participant in participants.participants {
|
||||
@ -397,6 +400,7 @@ func _internal_fetchAndUpdateCachedPeerData(accountPeerId: PeerId, peerId rawPee
|
||||
.withUpdatedCallJoinPeerId(groupCallDefaultJoinAs?.peerId)
|
||||
.withUpdatedThemeEmoticon(chatFullThemeEmoticon)
|
||||
.withUpdatedInviteRequestsPending(chatFullRequestsPending)
|
||||
.withUpdatedAutoremoveTimeout(autoremoveTimeout)
|
||||
.withUpdatedAllowedReactions(.known(mappedAllowedReactions))
|
||||
})
|
||||
case .channelFull:
|
||||
|
Loading…
x
Reference in New Issue
Block a user