We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent f2c3880 commit 751600eCopy full SHA for 751600e
Assets/WebGLTemplates/AgoraTemplate/AgoraWebSDK/libs/agorachannel.js
@@ -184,7 +184,7 @@ class AgoraChannel {
184
),
185
]);
186
187
- if (this.videoEnabled) {
+ if (this.client_role === 1 && this.videoEnabled) {
188
await this.setupLocalVideoTrack();
189
if (localTracks.videoTrack != undefined) {
190
localTracks.videoTrack.play("local-player");
@@ -193,7 +193,7 @@ class AgoraChannel {
193
this.is_publishing = true;
194
}
195
196
- if (this.audioEnabled) {
+ if (this.client_role === 1 && this.audioEnabled) {
197
await this.setupLocalAudioTrack();
198
if (localTracks.audioTrack != undefined) {
199
await this.client.publish(localTracks.audioTrack);
0 commit comments