Fix stale call preview state by finishing when leaving.

master
Cody Henthorne 2020-09-25 13:39:30 -04:00 committed by Alan Evans
parent 6448b84430
commit 8dbc721c08
1 changed files with 5 additions and 0 deletions

View File

@ -126,6 +126,11 @@ public class WebRtcCallActivity extends AppCompatActivity implements SafetyNumbe
if (!isInPipMode()) {
EventBus.getDefault().unregister(this);
}
CallParticipantsState state = viewModel.getCallParticipantsState().getValue();
if (state != null && state.getCallState() == WebRtcViewModel.State.CALL_PRE_JOIN) {
finish();
}
}
@Override