Skip to content

Commit

Permalink
Merge pull request #10824 from nextcloud/log-internal-signaling-messa…
Browse files Browse the repository at this point in the history
…ges-in-debug-mode

Log internal signaling messages in debug mode
  • Loading branch information
nickvergessen authored Nov 2, 2023
2 parents e51ccf7 + 2d2d9c7 commit 6fea609
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/utils/signaling.js
Original file line number Diff line number Diff line change
Expand Up @@ -478,6 +478,10 @@ Signaling.Internal.prototype._doLeaveRoom = function(token) {
}

Signaling.Internal.prototype.sendCallMessage = function(data) {
if (OC.debug) {
console.debug('Sending', data)
}

if (data.type === 'answer') {
console.debug('ANSWER', data)
} else if (data.type === 'offer') {
Expand Down Expand Up @@ -518,6 +522,10 @@ Signaling.Internal.prototype._startPullingMessages = function() {
result.data.ocs.data.forEach(message => {
let localParticipant

if (OC.debug) {
console.debug('Received', message)
}

this._trigger('onBeforeReceiveMessage', [message])
switch (message.type) {
case 'usersInRoom':
Expand Down

0 comments on commit 6fea609

Please sign in to comment.