Skip to content

fix(cc-components): correct recording state during hold/unhold operations#685

Open
bhabalan wants to merge 2 commits into
webex:nextfrom
bhabalan:CAI-7859
Open

fix(cc-components): correct recording state during hold/unhold operations#685
bhabalan wants to merge 2 commits into
webex:nextfrom
bhabalan:CAI-7859

Conversation

@bhabalan
Copy link
Copy Markdown
Contributor

@bhabalan bhabalan commented May 14, 2026

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

  • Fixed updateCallStateFromTask in call-control.utils.ts to use explicit string comparison (isPaused !== 'true') instead of boolean coercion (!isPaused)
  • The isPaused field from the backend is a string ("true" / "false"), not a boolean. Using !isPaused on string "false" evaluates to false (since any non-empty string is truthy), incorrectly marking recording as paused whenever the task reference updates (which happens on hold/unhold events)
  • Updated unit tests to use string values matching actual backend payloads
  • Added explicit test cases for string "true" and "false" isPaused values

Vidcast: https://app.vidcast.io/share/ec014ae7-eb0d-480a-9d67-af9ca7b0f523

Change Type

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Documentation update
  • Tooling change
  • Internal code refactor

The following scenarios were tested

  • Hold a call → recording indicator remains unchanged (not paused)
  • Manually pause recording → hold → unhold → recording stays paused
  • Manually resume recording while on hold → unhold → recording stays resumed
  • Unit tests pass: yarn workspace @webex/cc-components exec jest --testPathPattern="call-control.utils" (46 tests pass)
  • Verified via HAR file analysis that backend sends isPaused: "false" (string) in hold/unhold payloads

The GAI Coding Policy And Copyright Annotation Best Practices

  • GAI was not used (or, no additional notation is required)
  • Code was generated entirely by GAI
  • GAI was used to create a draft that was subsequently customized or modified
  • Coder created a draft manually that was non-substantively modified by GAI (e.g., refactoring was performed by GAI on manually written code)
  • Tool used for AI assistance (GitHub Copilot / Other - specify)
    • Github Copilot
    • Other - Claude Code
  • This PR is related to
    • Feature
    • Defect fix
    • Tech Debt
    • Automation

Checklist before merging

  • I have not skipped any automated checks
  • All existing and new tests passed
  • I have updated the testing document
  • I have tested the functionality with amplify link

Make sure to have followed the contributing guidelines before submitting.

…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
@bhabalan bhabalan marked this pull request as ready for review May 14, 2026 01:57
@bhabalan bhabalan requested a review from a team as a code owner May 14, 2026 01:57
@bhabalan bhabalan added validated Indicates that the PR is ready for actions run_e2e Add this label to run E2E test for meeting and CC widgets labels May 14, 2026
@aws-amplify-us-east-2
Copy link
Copy Markdown

This pull request is automatically being deployed by Amplify Hosting (learn more).

Access this pull request here: https://pr-685.d1b38q61t1z947.amplifyapp.com

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

Labels

run_e2e Add this label to run E2E test for meeting and CC widgets validated Indicates that the PR is ready for actions

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant