mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-06-16 05:55:20 +00:00
Merge branch 'master' of gitlab.com:peter-iakovlev/telegram-ios
This commit is contained in:
commit
1946dffa2d
@ -103,6 +103,19 @@ public func sendAuthorizationCode(accountManager: AccountManager<TelegramAccount
|
||||
|> map { sentCode in
|
||||
return (.sentCode(sentCode), updatedAccount)
|
||||
}
|
||||
|> `catch` { error -> Signal<(SendCodeResult, UnauthorizedAccount), MTRpcError> in
|
||||
if error.errorDescription == "SESSION_PASSWORD_NEEDED" {
|
||||
return account.network.request(Api.functions.account.getPassword(), automaticFloodWait: false)
|
||||
|> mapToSignal { result -> Signal<(SendCodeResult, UnauthorizedAccount), MTRpcError> in
|
||||
switch result {
|
||||
case let .password(_, _, _, _, hint, _, _, _, _, _):
|
||||
return .single((.password(hint: hint), account))
|
||||
}
|
||||
}
|
||||
} else {
|
||||
return .fail(error)
|
||||
}
|
||||
}
|
||||
}
|
||||
case _:
|
||||
return .fail(error)
|
||||
|
@ -942,7 +942,7 @@ final class ChatMessageInteractiveFileNode: ASDisplayNode {
|
||||
statusNode.backgroundNodeColor = backgroundNodeColor
|
||||
}
|
||||
|
||||
if state != .none && isVoice && self.playbackAudioLevelNode == nil {
|
||||
if case .pause = state, isVoice, self.playbackAudioLevelNode == nil {
|
||||
let blobFrame = progressFrame.insetBy(dx: -12.0, dy: -12.0)
|
||||
let playbackAudioLevelNode = VoiceBlobNode(
|
||||
maxLevel: 0.3,
|
||||
|
Loading…
x
Reference in New Issue
Block a user