diff --git a/public/index.js b/public/index.js index ef096c3..456486c 100644 --- a/public/index.js +++ b/public/index.js @@ -209,24 +209,21 @@ const getRtpCapabilities = () => { const createSendTransport = () => { - // setTimeout(() => { - // const answer = { - // origin_asset_id: ASSET_ID, - // dest_asset_id: originAssetId || parseInt(urlParams.get('dest_asset_id')), - // type: 'notify-answer', - // origin_asset_priority: 1, - // origin_asset_type_name: ASSET_TYPE, - // origin_asset_name: ASSET_NAME, - // video_call_id: callId, - // answer: 'accepted', // answer: 'rejected' - // }; + const answer = { + origin_asset_id: ASSET_ID, + dest_asset_id: originAssetId || parseInt(urlParams.get('dest_asset_id')), + type: 'notify-answer', + origin_asset_priority: 1, + origin_asset_type_name: ASSET_TYPE, + origin_asset_name: ASSET_NAME, + video_call_id: callId, + answer: 'accepted', // answer: 'rejected' + }; console.log('SEND answer', answer); hub.emit( 'video', JSON.stringify(answer) ); - // device === undefined ? getRtpCapabilities() : goCreateTransport() - // }, 7000); // see server's socket.on('createWebRtcTransport', sender?, ...) // this is a call from Producer, so sender = true