8000 [iOS] fix removeTrack methodChannel response, onTrack's `stream` and `track` not being registered in native. by Ayman-Kortobaa · Pull Request #404 · flutter-webrtc/flutter-webrtc · GitHub
[go: up one dir, main page]

Skip to content

[iOS] fix removeTrack methodChannel response, onTrack's stream and track not being registered in native. #404

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged

Conversation

Ayman-Kortobaa
Copy link
Contributor

This pull request is for two issues:

  1. The removeTrackmethod in rtc_peerconnection_impl.dart anticipates a boolean in Map with result as a key
	bool result = response['result'];

       but the removeTrack in Darwin's sends nil which throws The Method '[ ]' was called on null "result" in Dart.

  1. The second issue was not registering stream and track in onTrack for PeerConnection - didAddReceiver in Obj-c - which results into a Not found video track for RTCMediaStream: {streamId} error.

Related issues:

  1. [iOS] The Method '[ ]' was called on null "result" when calling 8000 PeerConnection's removeTrack #402
  2. [iOS] Not found video track for RTCMediaStream: {streamId} error when using Unified-Plan onTrack and videos don't render. #403

… Dart code expects a boolean and throws []"result" called on null.
…und video track for RTCMediaStream: {streamId}` in onTrack for Unified-plan as they are not being added to native.
@cloudwebrtc
Copy link
Member

LGTM

@cloudwebrtc cloudwebrtc merged commit 1a51904 into flutter-webrtc:master Nov 5, 2020
@Ayman-Kortobaa Ayman-Kortobaa deleted the ios-removetrack-ontrack-fix branch November 9, 2020 11:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants
0