feat: give more time for calls to connect

pull/687/head
Ryan Zhao 2 years ago
parent 31605672e2
commit e3479107f3

@ -71,6 +71,7 @@ public final class SessionCall: CurrentCallProtocol, WebRTCSessionDelegate {
var connectingDate: Date? {
didSet {
stateDidChange?()
resetTimeoutTimerIfNeeded()
hasStartedConnectingDidChange?()
}
}
@ -421,6 +422,11 @@ public final class SessionCall: CurrentCallProtocol, WebRTCSessionDelegate {
}
}
public func resetTimeoutTimerIfNeeded() {
if self.timeOutTimer == nil { return }
setupTimeoutTimer()
}
public func invalidateTimeoutTimer() {
timeOutTimer?.invalidate()
timeOutTimer = nil

Loading…
Cancel
Save