webrtc: update werift

This commit is contained in:
Koushik Dutta
2024-03-17 19:48:24 -07:00
parent 370b63584a
commit 64137c796e
5 changed files with 6 additions and 6 deletions

View File

@@ -1,12 +1,12 @@
{
"name": "@scrypted/webrtc",
"version": "0.2.14",
"version": "0.2.16",
"lockfileVersion": 2,
"requires": true,
"packages": {
"": {
"name": "@scrypted/webrtc",
"version": "0.2.14",
"version": "0.2.16",
"dependencies": {
"@scrypted/common": "file:../../common",
"@scrypted/sdk": "file:../../sdk",

View File

@@ -1,6 +1,6 @@
{
"name": "@scrypted/webrtc",
"version": "0.2.14",
"version": "0.2.16",
"scripts": {
"scrypted-setup-project": "scrypted-setup-project",
"prescrypted-setup-project": "scrypted-package-json",

View File

@@ -649,7 +649,7 @@ export async function fork() {
cleanup.promise.finally(() => socket.destroy());
const dc = pc.createDataChannel('rpc');
dc.message.subscribe(message => socket.write(message));
dc.onMessage.subscribe(message => socket.write(message));
const debouncer = new DataChannelDebouncer({
send: u8 => dc.send(Buffer.from(u8)),

View File

@@ -54,7 +54,7 @@ export function isLocalIceTransport(pc: RTCPeerConnection) {
let isLocalNetwork = true;
let destinationId: string;
for (const ice of pc.iceTransports) {
const { remoteAddr, localCandidate } = (ice.connection as any).nominated[1];
const { remoteAddr, localCandidate } = (ice.connection as any).nominated;
const [address, port] = remoteAddr;
if (!destinationId)
destinationId = address;