Skip to content

Commit

Permalink
Merge pull request #833 from tannera926/master
Browse files Browse the repository at this point in the history
Adding silentMonitor and bargeIn functions
  • Loading branch information
tannera926 authored Jan 18, 2024
2 parents bfd190f + f2307d3 commit 1aa9933
Show file tree
Hide file tree
Showing 5 changed files with 19 additions and 3 deletions.
2 changes: 1 addition & 1 deletion release/connect-streams-dr-min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion release/connect-streams-dr.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion release/connect-streams-min.js

Large diffs are not rendered by default.

8 changes: 8 additions & 0 deletions release/connect-streams.js
Original file line number Diff line number Diff line change
Expand Up @@ -1430,6 +1430,14 @@
var supervisorConnection = nonAgentConnections && nonAgentConnections.find(conn => conn.isBarge() && conn.isActive());
return supervisorConnection !== undefined;
}

Contact.prototype.silentMonitor = function (callbacks) {
return this.updateMonitorParticipantState(connect.MonitoringMode.SILENT_MONITOR, callbacks);
}

Contact.prototype.bargeIn = function (callbacks) {
return this.updateMonitorParticipantState(connect.MonitoringMode.BARGE, callbacks);
}

Contact.prototype.pause = function (callbacks) {
var client = connect.core.getClient();
Expand Down
8 changes: 8 additions & 0 deletions src/api.js
Original file line number Diff line number Diff line change
Expand Up @@ -1236,6 +1236,14 @@
var supervisorConnection = nonAgentConnections && nonAgentConnections.find(conn => conn.isBarge() && conn.isActive());
return supervisorConnection !== undefined;
}

Contact.prototype.silentMonitor = function (callbacks) {
return this.updateMonitorParticipantState(connect.MonitoringMode.SILENT_MONITOR, callbacks);
}

Contact.prototype.bargeIn = function (callbacks) {
return this.updateMonitorParticipantState(connect.MonitoringMode.BARGE, callbacks);
}

Contact.prototype.pause = function (callbacks) {
var client = connect.core.getClient();
Expand Down

0 comments on commit 1aa9933

Please sign in to comment.