[webrtc-pc] insertDTMF is synchronous, but relies on asynchronous state-checking logic (#2738)

docfaraday has just created a new issue for https://github.com/w3c/webrtc-pc:

== insertDTMF is synchronous, but relies on asynchronous state-checking logic ==
The steps for insertDTMF include the following:

"If [determine if DTMF can be sent](https://w3c.github.io/webrtc-pc/#dfn-determine-if-dtmf-can-be-sent) for dtmf returns false, [throw](https://webidl.spec.whatwg.org/#dfn-throw) an [InvalidStateError](https://webidl.spec.whatwg.org/#invalidstateerror)."

However, [determine if DTMF can be sent](https://w3c.github.io/webrtc-pc/#dfn-determine-if-dtmf-can-be-sent) says it is performed in a queued task.

We either need to make "[determine if DTMF can be sent](https://w3c.github.io/webrtc-pc/#dfn-determine-if-dtmf-can-be-sent" synchronous, or we need to make insertDTMF return a promise, and make its validation logic async.

Please view or discuss this issue at https://github.com/w3c/webrtc-pc/issues/2738 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Wednesday, 18 May 2022 15:50:48 UTC