We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent d7945ee commit 914b541Copy full SHA for 914b541
lib/src/mediadevices_impl.dart
@@ -13,9 +13,14 @@ class MediaDevicesWeb extends MediaDevices {
13
Map<String, dynamic> mediaConstraints) async {
14
try {
15
if (!isMobile) {
16
- if (mediaConstraints['video'] is Map &&
17
- mediaConstraints['video']['facingMode'] != null) {
18
- mediaConstraints['video'].remove('facingMode');
+ try {
+ if (mediaConstraints['video'] is Map &&
+ mediaConstraints['video']['facingMode'] != null) {
19
+ mediaConstraints['video'].remove('facingMode');
20
+ }
21
+ } catch (e) {
22
+ print(
23
+ '[getUserMedia] failed to remove facingMode from mediaConstraints');
24
}
25
26
0 commit comments