refactor: failed and disconnect events only handled if either the reconnect or the timeout runnables are not set
This commit is contained in:
parent
4c984de9ff
commit
413e65e905
|
@ -807,7 +807,7 @@ class WebRtcCallService: Service(), CallManager.WebRtcListener {
|
|||
val intent = Intent(this, WebRtcCallService::class.java)
|
||||
.setAction(ACTION_ICE_CONNECTED)
|
||||
startService(intent)
|
||||
} else if (newState in arrayOf(FAILED, DISCONNECTED) && scheduledReconnect == null) {
|
||||
} else if (newState in arrayOf(FAILED, DISCONNECTED) && (scheduledReconnect == null && scheduledTimeout == null)) {
|
||||
callManager.callId?.let { callId ->
|
||||
callManager.postConnectionEvent(Event.IceDisconnect) {
|
||||
callManager.postViewModelState(CallViewModel.State.CALL_RECONNECTING)
|
||||
|
|
Loading…
Reference in New Issue