[*] bug
This commit is contained in:
@@ -1343,7 +1343,7 @@ class Taoyao {
|
||||
...webRtcTransportOptions,
|
||||
webRtcServer: room.webRtcServer,
|
||||
});
|
||||
me.transportEvent("webrtc", roomId, transport);
|
||||
self.transportEvent("webrtc", roomId, transport);
|
||||
transport.clientId = clientId;
|
||||
room.transports.set(transport.id, transport);
|
||||
message.body = {
|
||||
@@ -1371,6 +1371,7 @@ class Taoyao {
|
||||
* @param {*} transport 通道
|
||||
*/
|
||||
transportEvent(type, roomId, transport) {
|
||||
const self = this;
|
||||
/********************* 通用通道事件 *********************/
|
||||
transport.on("routerclose", () => {
|
||||
console.info("transport routerclose:", transport.id);
|
||||
|
||||
@@ -586,11 +586,11 @@ class Taoyao extends RemoteClient {
|
||||
/************************ 管理 ************************/
|
||||
getProducer(producerId) {
|
||||
const me = this;
|
||||
if(me?.audioProducer.id === producerId) {
|
||||
if(me.audioProducer?.id === producerId) {
|
||||
return me.audioProducer;
|
||||
} else if(me?.videoProducer.id === producerId) {
|
||||
} else if(me.videoProducer?.id === producerId) {
|
||||
return me.videoProducer;
|
||||
} else if(me?.dataProducer.id === producerId) {
|
||||
} else if(me.dataProducer?.id === producerId) {
|
||||
return me.dataProducer;
|
||||
} else {
|
||||
return null;
|
||||
|
||||
Reference in New Issue
Block a user