From 1a89986990a4657680b9718774fe0bd8aa33b837 Mon Sep 17 00:00:00 2001 From: Ilya Laktyushin Date: Sat, 22 Feb 2025 21:35:07 +0400 Subject: [PATCH] Fix --- .../TelegramUI/Sources/Chat/ChatControllerPaidMessage.swift | 3 +++ 1 file changed, 3 insertions(+) diff --git a/submodules/TelegramUI/Sources/Chat/ChatControllerPaidMessage.swift b/submodules/TelegramUI/Sources/Chat/ChatControllerPaidMessage.swift index 108a6a64ff..259e63a313 100644 --- a/submodules/TelegramUI/Sources/Chat/ChatControllerPaidMessage.swift +++ b/submodules/TelegramUI/Sources/Chat/ChatControllerPaidMessage.swift @@ -17,6 +17,7 @@ import TelegramNotices extension ChatControllerImpl { func presentPaidMessageAlertIfNeeded(count: Int32 = 1, forceDark: Bool = false, completion: @escaping (Bool) -> Void) { guard let peer = self.presentationInterfaceState.renderedPeer?.peer.flatMap(EnginePeer.init) else { + completion(false) return } if let sendPaidMessageStars = self.presentationInterfaceState.sendPaidMessageStars { @@ -71,6 +72,8 @@ extension ChatControllerImpl { self.present(controller, in: .window(.root)) } }) + } else { + completion(false) } }