Fixed messenger in IE11.

This commit is contained in:
Ylian Saint-Hilaire 2018-12-20 15:55:28 -08:00
parent bd5d52ccc7
commit dc6b9217a9
2 changed files with 4 additions and 5 deletions

View File

@ -1,6 +1,6 @@
{
"name": "meshcentral",
"version": "0.2.5-a",
"version": "0.2.5-b",
"keywords": [
"Remote Management",
"Intel AMT",

View File

@ -116,14 +116,13 @@
// 0 = nomedia, 1 = miconly, 2 = mic&cam
function getUserMediaSupport(func) {
try {
navigator.mediaDevices.enumerateDevices()
.then(devices => {
navigator.mediaDevices.enumerateDevices().then(function (devices) {
try {
var mic = 0, cam = 0;
devices.forEach(device => {
devices.forEach(function (device) {
if (device.kind === 'audioinput') { mic = 1; }
if (device.kind === 'videoinput') { cam = 1; }
})
});
if (mic == 0) { func(0); }
func(mic + cam);
} catch (ex) { }