Overloading destroy method instead of having a separate method to remove video.
This commit is contained in:
@@ -189,7 +189,7 @@ export class SimplePeer {
|
||||
console.warn("Tried to close connection for user "+userId+" but could not find user")
|
||||
return;
|
||||
}
|
||||
peer.closeConnection();
|
||||
peer.destroy();
|
||||
// FIXME: I don't understand why "Closing connection with" message is displayed TWICE before "Nb users in peerConnectionArray"
|
||||
// I do understand the method closeConnection is called twice, but I don't understand how they manage to run in parallel.
|
||||
//console.log('Closing connection with '+userId);
|
||||
@@ -220,7 +220,7 @@ export class SimplePeer {
|
||||
// FIXME: I don't understand why "Closing connection with" message is displayed TWICE before "Nb users in peerConnectionArray"
|
||||
// I do understand the method closeConnection is called twice, but I don't understand how they manage to run in parallel.
|
||||
//console.log('Closing connection with '+userId);
|
||||
peer.closeScreenSharingConnection();
|
||||
peer.destroy();
|
||||
this.PeerScreenSharingConnectionArray.delete(userId)
|
||||
//console.log('Nb users in peerConnectionArray '+this.PeerConnectionArray.size);
|
||||
} catch (err) {
|
||||
|
||||
Reference in New Issue
Block a user