Don't break if you press the hangup button before allowing media permission.

pull/10/head
David Baker 2014-09-09 17:52:01 +01:00
parent 253c327252
commit 25e96f82db
2 changed files with 3 additions and 2 deletions

View File

@ -104,7 +104,7 @@ angular.module('MatrixCall', [])
console.trace("Ending call "+this.call_id);
this.stopAllMedia();
this.peerConn.close();
if (this.peerConn) this.peerConn.close();
this.hangupParty = 'local';

View File

@ -58,7 +58,8 @@
<span ng-show="currentCall.state == 'invite_sent'">Calling...</span>
<span ng-show="currentCall.state == 'connecting'">Call Connecting...</span>
<span ng-show="currentCall.state == 'connected'">Call Connected</span>
<span ng-show="currentCall.state == 'ended' && !currentCall.didConnect && currentCall.direction == 'outbound'">Call Rejected</span>
<span ng-show="currentCall.state == 'ended' && !currentCall.didConnect && currentCall.direction == 'outbound' && currentCall.hangupParty == 'remote'">Call Rejected</span>
<span ng-show="currentCall.state == 'ended' && !currentCall.didConnect && currentCall.direction == 'outbound' && currentCall.hangupParty == 'local'">Call Canceled</span>
<span ng-show="currentCall.state == 'ended' && currentCall.didConnect && currentCall.direction == 'outbound'">Call Ended</span>
<span ng-show="currentCall.state == 'ended' && !currentCall.didConnect && currentCall.direction == 'inbound'">Call Canceled</span>
<span ng-show="currentCall.state == 'ended' && currentCall.didConnect && currentCall.direction == 'inbound'">Call Ended</span>