Fix call termination when muting before call is connected.

This commit is contained in:
Alex Hart 2020-04-22 13:29:14 -03:00 committed by Greyson Parrelli
parent 9742a212a2
commit 8ad61a52b9

View file

@ -492,10 +492,12 @@ public class WebRtcCallService extends Service implements CallManager.Observer,
return;
}
try {
callManager.setAudioEnable(microphoneEnabled);
} catch (CallException e) {
callFailure("Enabling audio failed: ", e);
if (activePeer.getState() == CallState.CONNECTED) {
try {
callManager.setAudioEnable(microphoneEnabled);
} catch (CallException e) {
callFailure("Enabling audio failed: ", e);
}
}
if (activePeer != null) {