Skip to content

breaking: remove deprecated removeCCPAState method#1237

Open
rmi22186 wants to merge 3 commits intomasterfrom
breaking/remove-removeCCPAState
Open

breaking: remove deprecated removeCCPAState method#1237
rmi22186 wants to merge 3 commits intomasterfrom
breaking/remove-removeCCPAState

Conversation

@rmi22186
Copy link
Copy Markdown
Member

@rmi22186 rmi22186 commented Apr 3, 2026

Summary

  • Removes the deprecated removeCCPAState method from the consent module. Users should use removeCCPAConsentState instead.
  • Removes the removeCCPAState property from the IConsentState interface and associated TODO comments.
  • Removes the test case that validated the deprecation warning for removeCCPAState.

Breaking Change

removeCCPAState was deprecated in favor of removeCCPAConsentState. This PR completes that deprecation by removing the method entirely. Any consumers still calling removeCCPAState must migrate to removeCCPAConsentState.

Test plan

  • Verify existing consent tests pass (no test regressions from removal)
  • Verify TypeScript compilation succeeds
  • Confirm no remaining references to removeCCPAState in source (only CHANGELOG history)

🤖 Generated with Claude Code

rmi22186 and others added 3 commits April 3, 2026 09:46
Remove the deprecated `removeCCPAState` method and associated code/tests.
Users should use `removeCCPAConsentState` instead.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
IConsentState was an empty extension of ConsentState that added no
properties. Replace usages with ConsentState directly.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
The TODO indicated this cast should be removed once removeCCPAState was
removed. Since removeCCPAState is being removed in this PR, the cast is
no longer needed.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@sonarqubecloud
Copy link
Copy Markdown

sonarqubecloud bot commented Apr 3, 2026

@rmi22186 rmi22186 marked this pull request as ready for review April 3, 2026 19:24
@rmi22186 rmi22186 requested a review from a team as a code owner April 3, 2026 19:24
@cursor
Copy link
Copy Markdown

cursor bot commented Apr 3, 2026

PR Summary

Medium Risk
This is a breaking public API removal from the consent state object, which can cause runtime failures for any downstream code still calling removeCCPAState. Core consent behavior is otherwise unchanged.

Overview
Removes the deprecated removeCCPAState method from the consent state returned by Consent.createConsentState, including the IConsentState type, deprecation warning, and related TODOs.

Updates createConsentState to return plain ConsentState without casting, and deletes the test that asserted the deprecated warning/behavior; consumers must use removeCCPAConsentState instead.

Written by Cursor Bugbot for commit 8f70c58. This will update automatically on new commits. Configure here.

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.

1 participant