File tree Expand file tree Collapse file tree
packages/tui-components-svelte/src/lib/media/ui/settings/select Expand file tree Collapse file tree Original file line number Diff line number Diff line change 2525 // NOTE: Using onfocus instead of onclick, as onclick is not always triggered in Safari
2626 if (media .cam_devices .length === 0 || getMediaSuccess .cam === false ) {
2727 console .debug (" [SelectCam] onfocus: No devices found, requesting permission" )
28- let stream = await getCam (null )
29- stream .getTracks ().forEach ((track ) => track .stop ())
28+ try {
29+ let stream = await getCam (null )
30+ stream .getTracks ().forEach ((track ) => track .stop ())
31+ } catch (e ) {
32+ console .error (" [SelectCam] onfocus: Error requesting permission" , e )
33+ }
3034 }
3135 }}
3236/>
Original file line number Diff line number Diff line change 2525 if (media .mic_devices .length === 0 || getMediaSuccess .mic === false ) {
2626 // NOTE: Using onfocus instead of onclick, as onclick is not always triggered in Safari
2727 console .debug (" [SelectMic] onfocus: No devices found, requesting permission" )
28- let stream = await getMic (null )
29- stream .getTracks ().forEach ((track ) => track .stop ())
28+ try {
29+ let stream = await getMic (null )
30+ stream .getTracks ().forEach ((track ) => track .stop ())
31+ } catch (e ) {
32+ console .error (" [SelectMic] onfocus: Error requesting permission" , e )
33+ }
3034 }
3135 }}
3236/>
You can’t perform that action at this time.
0 commit comments