webrtc-adapter
Advanced tools
Comparing version 7.6.4 to 7.7.0
@@ -278,3 +278,5 @@ /* | ||
var params = sender.getParameters(); | ||
if (!('encodings' in params)) { | ||
if (!('encodings' in params) || | ||
// Avoid being fooled by patched getParameters() below. | ||
params.encodings.length === 1 && Object.keys(params.encodings[0]).length === 0) { | ||
params.encodings = initParameters.sendEncodings; | ||
@@ -302,6 +304,6 @@ sender.sendEncodings = initParameters.sendEncodings; | ||
var params = origGetParameters.apply(this, arguments); | ||
if (!('sendEncodings' in this)) { | ||
return params; | ||
if (!('encodings' in params)) { | ||
params.encodings = [].concat(this.sendEncodings || [{}]); | ||
} | ||
return Object.assign({}, { encodings: this.sendEncodings }, params); | ||
return params; | ||
}; | ||
@@ -308,0 +310,0 @@ } |
{ | ||
"name": "webrtc-adapter", | ||
"version": "7.6.4", | ||
"version": "7.7.0", | ||
"description": "A shim to insulate apps from WebRTC spec changes and browser prefix differences", | ||
@@ -5,0 +5,0 @@ "license": "BSD-3-Clause", |
@@ -22,3 +22,3 @@ /* | ||
if (server && (server.urls || server.url)) { | ||
var urls = server.urls || server.url; | ||
let urls = server.urls || server.url; | ||
if (server.url && !server.urls) { | ||
@@ -25,0 +25,0 @@ utils.deprecated('RTCIceServer.url', 'RTCIceServer.urls'); |
@@ -241,3 +241,6 @@ /* | ||
const params = sender.getParameters(); | ||
if (!('encodings' in params)) { | ||
if (!('encodings' in params) || | ||
// Avoid being fooled by patched getParameters() below. | ||
(params.encodings.length === 1 && | ||
Object.keys(params.encodings[0]).length === 0)) { | ||
params.encodings = initParameters.sendEncodings; | ||
@@ -267,7 +270,7 @@ sender.sendEncodings = initParameters.sendEncodings; | ||
function getParameters() { | ||
var params = origGetParameters.apply(this, arguments); | ||
if (!('sendEncodings' in this)) { | ||
return params; | ||
const params = origGetParameters.apply(this, arguments); | ||
if (!('encodings' in params)) { | ||
params.encodings = [].concat(this.sendEncodings || [{}]); | ||
} | ||
return Object.assign({}, {encodings: this.sendEncodings}, params); | ||
return params; | ||
}; | ||
@@ -274,0 +277,0 @@ } |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
873407
46
21778