Skip to content
This repository has been archived by the owner on Sep 11, 2024. It is now read-only.

Commit

Permalink
Add logging for which rooms calls are in
Browse files Browse the repository at this point in the history
  • Loading branch information
dbkr committed Jun 9, 2021
1 parent 66a953a commit bd8fd24
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/CallHandler.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -542,6 +542,7 @@ export default class CallHandler extends EventEmitter {
if (newMappedRoomId !== mappedRoomId) {
this.removeCallForRoom(mappedRoomId);
mappedRoomId = newMappedRoomId;
console.log("Moving call to room " + mappedRoomId);
this.calls.set(mappedRoomId, call);
this.emit(CallHandlerEvent.CallChangeRoom, call);
}
Expand Down Expand Up @@ -607,6 +608,7 @@ export default class CallHandler extends EventEmitter {
}

private removeCallForRoom(roomId: string) {
console.log("Removing call for room ", roomId);
this.calls.delete(roomId);
this.emit(CallHandlerEvent.CallsChanged, this.calls);
}
Expand Down Expand Up @@ -680,6 +682,7 @@ export default class CallHandler extends EventEmitter {
console.log("Current turn creds expire in " + timeUntilTurnCresExpire + " ms");
const call = MatrixClientPeg.get().createCall(mappedRoomId);

console.log("Adding call for room ", roomId);
this.calls.set(roomId, call);
this.emit(CallHandlerEvent.CallsChanged, this.calls);
if (transferee) {
Expand Down Expand Up @@ -812,6 +815,7 @@ export default class CallHandler extends EventEmitter {
}

Analytics.trackEvent('voip', 'receiveCall', 'type', call.type);
console.log("Adding call for room ", mappedRoomId);
this.calls.set(mappedRoomId, call)
this.emit(CallHandlerEvent.CallsChanged, this.calls);
this.setCallListeners(call);
Expand Down

0 comments on commit bd8fd24

Please sign in to comment.