Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The signature for RTCPeerConnection.setLocalDescription has been overriden, as of #386, to have a mandatory argument. This is no longer the case; see specs here:
https://w3c.github.io/webrtc-pc/#dom-peerconnection-setlocaldescription
https://developer.mozilla.org/en-US/docs/Web/API/RTCPeerConnection/setLocalDescription#Parameters
This PR makes it optional, as it should be.
Resolves #875
Resolves microsoft/TypeScript#41939
Resolves microsoft/TypeScript#39142
Props to @jcc10 and @simonwep for finding this bug before me, but trying to fix it by modifying the generated declaration files, instead of here (as per these instructions). I think this should solve the problem for good and finally stop TypeScript from complaining about the argument count?
That being said, I still think that webidl2 needs to be looked at, as @simonwep said in #875, because in this file after line 44565 there should be
"optional": 1
, (like #386, this is all from 2018) but I deliberatiely didn't touch that since I'm thinking it needs to be fixed upstream.