File tree Expand file tree Collapse file tree 2 files changed +11
-1
lines changed
packages/ui-voip/src/providers Expand file tree Collapse file tree 2 files changed +11
-1
lines changed Original file line number Diff line number Diff line change 1+ ---
2+ " @rocket.chat/ui-voip " : patch
3+ ---
4+
5+ Fixes incoming VoIP calls playing "dial" sound when answered
Original file line number Diff line number Diff line change @@ -69,7 +69,12 @@ const VoipProvider = ({ children }: { children: ReactNode }) => {
6969 } ;
7070
7171 const onOutgoingCallRinging = ( ) : void => {
72- voipSounds . playDialer ( ) ;
72+ // VoipClient 'outgoingcall' event is emitted when the call is establishing
73+ // and that event is also emitted when the call is accepted
74+ // to avoid disrupting the VoipClient flow, we check if the call is outgoing here.
75+ if ( voipClient . isOutgoing ( ) ) {
76+ voipSounds . playDialer ( ) ;
77+ }
7378 } ;
7479
7580 const onIncomingCallRinging = ( ) : void => {
You can’t perform that action at this time.
0 commit comments