fix(cc-components): correct recording state during hold/unhold operations#685
Open
bhabalan wants to merge 2 commits into
Open
fix(cc-components): correct recording state during hold/unhold operations#685bhabalan wants to merge 2 commits into
bhabalan wants to merge 2 commits into
Conversation
…ions
The recording indicator incorrectly showed paused state when a call was
held because isPaused from the backend is a string ("true"/"false"), not
a boolean. Using !isPaused on string "false" evaluates to false, causing
the UI to show recording as paused. Changed to explicit string comparison.
COMPLETES CAI-7859
|
This pull request is automatically being deployed by Amplify Hosting (learn more). |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
COMPLETES https://jira-eng-sjc12.cisco.com/jira/browse/CAI-7859
This pull request addresses
The recording indicator incorrectly shows "paused" state when a call is put on hold. Additionally, after manually resuming recording while on hold, unholding the call resets the recording indicator back to paused. This behavior is inconsistent with the first-party Agent Desktop.
by making the following changes
updateCallStateFromTaskincall-control.utils.tsto use explicit string comparison (isPaused !== 'true') instead of boolean coercion (!isPaused)isPausedfield from the backend is a string ("true"/"false"), not a boolean. Using!isPausedon string"false"evaluates tofalse(since any non-empty string is truthy), incorrectly marking recording as paused whenever the task reference updates (which happens on hold/unhold events)"true"and"false"isPaused valuesVidcast: https://app.vidcast.io/share/ec014ae7-eb0d-480a-9d67-af9ca7b0f523
Change Type
The following scenarios were tested
yarn workspace @webex/cc-components exec jest --testPathPattern="call-control.utils"(46 tests pass)isPaused: "false"(string) in hold/unhold payloadsThe GAI Coding Policy And Copyright Annotation Best Practices
Checklist before merging
Make sure to have followed the contributing guidelines before submitting.