fix(gateway): swap stateChange arg order so Ready actually attaches UDP
djs/voice Networking emits stateChange(oldState, newState), but the watch
handler declared (newState, oldState) -- reversed. So the code-4 Ready
branch (which attaches udp.on('message') + logs 'DAVE watch READY') never
fired when entering Ready; it only fired spuriously when LEAVING Ready.
Result: full DAVE handshake completed on the watch RTC (Ready + DAVE MLA +
video stream 21029 active 1920x1080@60) but no UDP listener -> no video
captured. Swap to (oldState, newState) so enter-Ready wires the socket.
This commit is contained in:
1 parent
4534b7a17d
commit
4405647b33
1 file changed
+1
-1
@@ -271,7 +271,7 @@ function connectWatch(
|
|||||||
handleUdpMessage(watchKey, netAny, uidProps, msg);
|
handleUdpMessage(watchKey, netAny, uidProps, msg);
|
||||||
};
|
};
|
||||||
|
|
||||||
net.on("stateChange", (newState, oldState) => {
|
net.on("stateChange", (oldState, newState) => {
|
||||||
const s = newState as { code?: number };
|
const s = newState as { code?: number };
|
||||||
const code = s?.code;
|
const code = s?.code;
|
||||||
const oldCode = (oldState as { code?: number })?.code;
|
const oldCode = (oldState as { code?: number })?.code;
|
||||||
|
|||||||
Reference in new issue
Block a user