Skip to content

Commit

Permalink
filter screenshare robot user.
Browse files Browse the repository at this point in the history
  • Loading branch information
HeiSir committed Jan 25, 2021
1 parent 76f2b5c commit 31b9cef
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions static/scripts/app-index.js
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ const _app = new Vue({
that.myId = resp.self.id;
that.myRoomId = resp.id;

that.participants = resp.participants;
that.participants = resp.participants.filter(p => !/robot/.test(p.userId) );
that.remoteStreams = resp.remoteStreams.filter(r => r.source && r.source.video && r.source.video != 'mixed');

(that.enableAudio || that.enableVideo) && that.publishVideo();
Expand Down Expand Up @@ -233,7 +233,7 @@ const _app = new Vue({

e.participant.addEventListener('left',this.participantleft.bind(this,e.participant))

this.participants = this.conference.info.participants;
this.participants = this.conference.info.participants.filter(p => !/robot/.test(p.userId) );
console.log(this.conference.info);
var audio = new Audio('audio/some_one_join_room.wav'); // path to file
audio.play();
Expand All @@ -243,7 +243,7 @@ const _app = new Vue({
participantleft:function(participant,e){
console.log('participantleft',e);

this.participants = this.conference.info.participants;
this.participants = this.conference.info.participants.filter(p => !/robot/.test(p.userId) );
var audio = new Audio('audio/some_one_join_room.wav'); // path to file
audio.play();
audio = null;
Expand Down

0 comments on commit 31b9cef

Please sign in to comment.