meetecho / janus-gateway

Janus WebRTC Server
https://janus.conf.meetecho.com
GNU General Public License v3.0
8.23k stars 2.48k forks source link

PR #2044 breaks trickle candidate detection #2064

Closed agclark27 closed 4 years ago

agclark27 commented 4 years ago

The isTrickleEnabled(trickle) function as changed in PR #2044 is not functionally identical to the previous iteration. Specifically, we're seeing isTrickleEnabled being called where trickle=undefined.

Previously, when trickle=undefined, the following returns true.

return (trickle === false) ? false : true;

Now, with this change, it returns false.

https://github.com/meetecho/janus-gateway/blob/933c094b36354516bfa82ff56aecc6a296d8250c/html/janus.js#L3463

atoppi commented 4 years ago

Basically the PR transforms a true-by-default in a false-by-default check. I think the default should be true (being trickling a desirable feature in most cases).

lminiero commented 4 years ago

Feel free to propose fixes.