File tree Expand file tree Collapse file tree 1 file changed +3
-1
lines changed
packages/client/src/devices Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -11,7 +11,7 @@ import {
1111} from 'rxjs' ;
1212import { BrowserPermission } from './BrowserPermission' ;
1313import { lazy } from '../helpers/lazy' ;
14- import { isFirefox } from '../helpers/browsers' ;
14+ import { isFirefox , isSafari } from '../helpers/browsers' ;
1515import { dumpStream , Tracer } from '../stats' ;
1616import { getCurrentValue } from '../store/rxUtils' ;
1717import { videoLoggerSystem } from '../logger' ;
@@ -61,6 +61,8 @@ const getDevices = (
6161 */
6262export const checkIfAudioOutputChangeSupported = ( ) => {
6363 if ( typeof document === 'undefined' ) return false ;
64+ // Safari uses WebAudio API for playing audio, so we check the AudioContext prototype
65+ if ( isSafari ( ) ) return 'setSinkId' in AudioContext . prototype ;
6466 const element = document . createElement ( 'audio' ) ;
6567 return 'setSinkId' in element ;
6668} ;
You can’t perform that action at this time.
0 commit comments