Skip to content
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

Update mediaHandler.onopen to use mediaHandler.isMuted to mute/unmute #218

Closed
wants to merge 2 commits into from

Conversation

zyzmoz
Copy link

@zyzmoz zyzmoz commented Nov 28, 2023

Contributing to Twilio

All third party contributors acknowledge that any contributions they provide will be made under the same open source license that the open source project is provided under.

  • I acknowledge that all my contributions will be made under the project's license.

Pull Request Details

Updated mediaHandler.onopen to use its isMuted property when muting/unmuting the call

Description

It is possible to mute/unmute the call prior to the media opening, causing divergence between the actions performed (mute/unmute) and the actual state (which would be always unmuted)

Burndown

Before review

  • Added unit tests if necessary
  • Verified locally with npm test
  • Ready for review

Before merge

  • Got one or more +1s
  • Squashed erroneous commits if necessary
  • Re-tested if necessary

@charliesantos
Copy link
Collaborator

@zyzmoz thank you for submitting this PR. Can you please provide more details regarding the issue this PR is trying to solve? Such as steps to reproduce, expected and actual behavior.

@zyzmoz
Copy link
Author

zyzmoz commented Nov 29, 2023

So, when you make a call, you can mute or unmute that before the call is answered. If that call is muted and the other end answers, then the call will be unmuted by default. The changes I made solved that issue by using the mediaHandler state to mute/unmute the call when mediaHandler.onopen is triggered. Also, as the mediaHandler.isMuted default is false, the previous behaviour should be covered.

Steps to reproduce

  1. Make a call
  2. Mute on the Caller end without answering the call
  3. Callee answers the call

Result: Call gets unmuted

@charliesantos
Copy link
Collaborator

@zyzmoz I included your changes into this PR #227 along with other changes. Thank you for your contribution!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants