This commit is contained in:
Isaac
2025-07-01 19:38:35 +02:00
parent 7b18685825
commit 21e8bc02ca
6 changed files with 18 additions and 42 deletions

View File

@@ -2379,6 +2379,12 @@ public final class ChatControllerImpl: TelegramBaseController, ChatController, G
funds = (amount, amount.currency == .stars ? Int(configuration.channelMessageSuggestionStarsCommissionPermille) : Int(configuration.channelMessageSuggestionTonCommissionPermille))
}
#if DEBUG
if "".isEmpty {
funds = nil
}
#endif
var isAdmin = false
if let channel = strongSelf.presentationInterfaceState.renderedPeer?.peer as? TelegramChannel, channel.isMonoForum, let linkedMonoforumId = channel.linkedMonoforumId, let mainChannel = strongSelf.presentationInterfaceState.renderedPeer?.peers[linkedMonoforumId] as? TelegramChannel, mainChannel.hasPermission(.manageDirect) {
isAdmin = true