Issue #2332 - Update RTCIceCandidate to spec

Backport of https://bugzilla.mozilla.org/show_bug.cgi?id=1263312 - part 1
This commit is contained in:
Basilisk-Dev 2023-10-09 17:02:11 -04:00 committed by roytam1
commit ddf29677d9
2 changed files with 6 additions and 10 deletions

View file

@ -227,9 +227,7 @@ GlobalPCList.prototype = {
};
var _globalPCList = new GlobalPCList();
function RTCIceCandidate() {
this.candidate = this.sdpMid = this.sdpMLineIndex = null;
}
function RTCIceCandidate() {}
RTCIceCandidate.prototype = {
classDescription: "RTCIceCandidate",
classID: PC_ICE_CID,
@ -240,9 +238,7 @@ RTCIceCandidate.prototype = {
init: function(win) { this._win = win; },
__init: function(dict) {
this.candidate = dict.candidate;
this.sdpMid = dict.sdpMid;
this.sdpMLineIndex = ("sdpMLineIndex" in dict)? dict.sdpMLineIndex : null;
Object.assign(this, dict);
}
};