mirror of
https://github.com/ichmagmaus111/ghostgram.git
synced 2026-07-14 11:37:18 +02:00
Update Ghostgram features
This commit is contained in:
@@ -647,7 +647,7 @@ func chatHistoryEntriesForView(
|
||||
}
|
||||
}
|
||||
|
||||
if !dynamicAdMessages.isEmpty {
|
||||
if !MiscSettingsManager.shared.shouldBlockAds && !dynamicAdMessages.isEmpty {
|
||||
assert(entries.sorted() == entries)
|
||||
for message in dynamicAdMessages {
|
||||
entries.append(.MessageEntry(message, presentationData, false, nil, .none, ChatMessageEntryAttributes(rank: nil, isContact: false, contentTypeHint: .generic, updatingMedia: nil, isPlaying: false, isCentered: false, authorStoryStats: nil, displayContinueThreadFooter: false)))
|
||||
@@ -655,7 +655,7 @@ func chatHistoryEntriesForView(
|
||||
entries.sort()
|
||||
}
|
||||
|
||||
if view.laterId == nil && !view.isLoading {
|
||||
if !MiscSettingsManager.shared.shouldBlockAds && view.laterId == nil && !view.isLoading {
|
||||
if !entries.isEmpty, case let .MessageEntry(lastMessage, _, _, _, _, _) = entries[entries.count - 1], let message = adMessage {
|
||||
var nextAdMessageId: Int32 = 10000
|
||||
let updatedMessage = Message(
|
||||
|
||||
Reference in New Issue
Block a user