Video SDK Type and Version
1.10.8 for Web
Description
Attempting to send command like below-
export default class Zoom {
static #instance;
constructor() {
if (Zoom.#instance) {
throw new Error(
'Zoom singleton instance already exists. Use getInstance() method to access it.'
);
}
this.client = ZoomVideo.createClient();
this.commandChannel = this.client.getCommandClient();
this.stream = undefined;
this.localVideoTrack = undefined;
this.localAudioTrack = undefined;
this.localMicrophoneTester = undefined;
}
sendCommandToAll = async (text) => {
console.log('====>>>', {
commandChannel: this.commandChannel
});
await this.commandChannel.send('test');
};
onToggleMic() {
await this.sendCommandToAll(MeetingCommand.superHostMicOff);
}
}
this.client.on('command-channel-status', (payload) => {
console.log('======>>>>>', payload);
});
Error
@zoom_videosdk.js?v=0d7a067b:18082 Uncaught (in promise) TypeError: Cannot read properties of undefined (reading 'send')
at e6.value (@zoom_videosdk.js?v=0d7a067b:18082:21)
at Zoom.sendCommandToAll (Zoom.js:76:29)
Troubleshooting Routes
this.commandChannel
is not undefined (it is a Symbol).- Command channel status is coming as “Connected”
Still I am getting above error.