Skip to content

Release: 2.26.1#199

Closed
uc-brunosilva wants to merge 10 commits intomasterfrom
bump/2.26.1
Closed

Release: 2.26.1#199
uc-brunosilva wants to merge 10 commits intomasterfrom
bump/2.26.1

Conversation

@uc-brunosilva
Copy link
Copy Markdown
Collaborator

@uc-brunosilva uc-brunosilva commented Apr 6, 2026

User description

Release 2.26.1

Features

  • Added support for US National (GPP) privacy framework
  • Extended GPP API to Flutter, React Native and Unity bridges
  • Exposed DPS metadata via new getDpsMetadata() API
  • TCF resurfacing period now configurable via Admin UI (1–13 months)

Fixes

  • Fixed TCF resurfacing period logic
  • Fixed stored information not shown on DPS details
  • Fixed TCF maintain legitimate interest logic on Deny All
  • Fixed Android nullable type mismatch in setGPPConsent
  • Fixed iOS Swift closure return type in GppData+Dict

🤖 Generated with Claude Code


CodeAnt-AI Description

Release 2.26.1 for the React Native SDK

What Changed

  • Adds support for the US National privacy framework and extends GPP support in the React Native package
  • Exposes new DPS details through the SDK and makes the TCF resurfacing period configurable in the Admin UI
  • Fixes TCF resurfacing behavior and how legitimate interest is handled when users choose Deny All
  • Fixes stored information not appearing in DPS details, and corrects Android and iOS bridge issues that could block GPP consent updates

Impact

✅ US privacy support for React Native apps
✅ Clearer consent handling for Deny All flows
✅ Fewer broken GPP consent updates on Android and iOS

💡 Usage Guide

Checking Your Pull Request

Every time you make a pull request, our system automatically looks through it. We check for security issues, mistakes in how you're setting up your infrastructure, and common code problems. We do this to make sure your changes are solid and won't cause any trouble later.

Talking to CodeAnt AI

Got a question or need a hand with something in your pull request? You can easily get in touch with CodeAnt AI right here. Just type the following in a comment on your pull request, and replace "Your question here" with whatever you want to ask:

@codeant-ai ask: Your question here

This lets you have a chat with CodeAnt AI about your pull request, making it easier to understand and improve your code.

Example

@codeant-ai ask: Can you suggest a safer alternative to storing this secret?

Preserve Org Learnings with CodeAnt

You can record team preferences so CodeAnt AI applies them in future reviews. Reply directly to the specific CodeAnt AI suggestion (in the same thread) and replace "Your feedback here" with your input:

@codeant-ai: Your feedback here

This helps CodeAnt AI learn and adapt to your team's coding style and standards.

Example

@codeant-ai: Do not flag unused imports.

Retrigger review

Ask CodeAnt AI to review the PR again, by typing:

@codeant-ai: review

Check Your Repository Health

To analyze the health of your code repository, visit our dashboard at https://app.codeant.ai. This tool helps you identify potential issues and areas for improvement in your codebase, ensuring your repository maintains high standards of code health.

Summary by CodeRabbit

  • Release

    • 2.26.1 (Apr 07, 2026)
  • New Features

    • Support for US National (GPP) privacy framework
    • Expanded GPP API coverage for Flutter, React Native, and Unity
    • New getDpsMetadata() API to expose DPS metadata
    • TCF resurfacing period configurable in Admin UI (1–13 months)
  • Bug Fixes

    • Fixed TCF resurfacing period logic
    • Improved visibility of stored information on DPS details
    • Corrected TCF legitimate interest handling when Deny All selected

uc-brunosilva and others added 2 commits April 6, 2026 17:53
…pe in GPP

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@codeant-ai
Copy link
Copy Markdown

codeant-ai bot commented Apr 6, 2026

CodeAnt AI is reviewing your PR.


Thanks for using CodeAnt! 🎉

We're free for open-source projects. if you're enjoying it, help us grow by sharing.

Share on X ·
Reddit ·
LinkedIn

@qodo-code-review
Copy link
Copy Markdown

Review Summary by Qodo

Release 2.26.1 with GPP framework and bug fixes

✨ Enhancement 🐞 Bug fix

Grey Divider

Walkthroughs

Description
• Release version 2.26.1 with GPP privacy framework support
• Added US National (GPP) API to Flutter, React Native, Unity
• Exposed DPS metadata via new getDpsMetadata() API
• Fixed Android nullable type mismatch in setGPPConsent
• Fixed iOS Swift closure return type in GppData+Dict
• Made TCF resurfacing period configurable (1–13 months)
Diagram
flowchart LR
  A["Version Bump<br/>2.25.1 → 2.26.1"] --> B["GPP Framework<br/>Support Added"]
  A --> C["Bug Fixes"]
  B --> D["Extended to<br/>Flutter/React Native/Unity"]
  B --> E["DPS Metadata<br/>API Exposed"]
  C --> F["Android Nullable<br/>Type Fix"]
  C --> G["iOS Closure<br/>Return Type Fix"]
  C --> H["TCF Logic<br/>Improvements"]
Loading

Grey Divider

File Changes

1. android/build.gradle.kts ⚙️ Configuration changes +1/-1

Update Android build version

• Updated Usercentrics version from 2.25.1 to 2.26.1

android/build.gradle.kts


2. android/src/main/java/com/usercentrics/reactnative/RNUsercentricsModule.kt 🐞 Bug fix +1/-0

Fix Android nullable type in setGPPConsent

• Added null check guard clause after parsing GPP consent value
• Prevents passing null values to setGPPConsent method
• Resolves Android nullable type mismatch issue

android/src/main/java/com/usercentrics/reactnative/RNUsercentricsModule.kt


3. ios/Extensions/GppData+Dict.swift 🐞 Bug fix +1/-1

Fix iOS Swift closure return type

• Added explicit return type annotation -> Any to nested map closure
• Fixes Swift closure return type inference issue
• Ensures proper type handling in nested array mapping

ios/Extensions/GppData+Dict.swift


View more (2)
4. CHANGELOG.md 📝 Documentation +11/-0

Add 2.26.1 release notes to changelog

• Added release notes for version 2.26.1 dated Apr 07, 2026
• Documented new GPP framework support and API extensions
• Listed bug fixes for TCF logic and DPS metadata display

CHANGELOG.md


5. package.json ⚙️ Configuration changes +2/-2

Update package versions to 2.26.1

• Updated package version from 2.25.1 to 2.26.1
• Updated iOS package version from 2.25.1 to 2.26.1

package.json


Grey Divider

Qodo Logo

@qodo-code-review
Copy link
Copy Markdown

qodo-code-review bot commented Apr 6, 2026

Code Review by Qodo

🐞 Bugs (1) 📘 Rule violations (0) 📎 Requirement gaps (0) 🎨 UX Issues (0)

Grey Divider


Remediation recommended

1. Null GPP value dropped🐞 Bug ≡ Correctness
Description
RNUsercentricsModule.setGPPConsent on Android now returns early when the parsed value is null, so
calls with { value: null } are silently ignored. iOS continues to forward NSNull for the same
input, creating inconsistent cross-platform behavior for the React Native API.
Code

android/src/main/java/com/usercentrics/reactnative/RNUsercentricsModule.kt[R158-159]

+        parsedValue ?: return
 usercentricsProxy.instance.setGPPConsent(sectionName, fieldName, parsedValue)
Evidence
Android now explicitly exits before calling the underlying SDK when parsedValue is null. The
parser maps ReadableType.Null to null, so { value: null } from JS is guaranteed to hit this
path. The JS wrapper accepts unknown and forwards it without validation, and the iOS bridge
forwards missing/null values as NSNull into setGPPConsent, so platform behavior diverges for the
same JS input.

android/src/main/java/com/usercentrics/reactnative/RNUsercentricsModule.kt[150-160]
android/src/main/java/com/usercentrics/reactnative/RNUsercentricsModule.kt[291-300]
src/Usercentrics.tsx[156-159]
ios/RNUsercentricsModule.swift[153-156]

Agent prompt
The issue below was found during a code review. Follow the provided context and guidance below and implement a solution

## Issue description
Android `setGPPConsent` silently drops `null` values (`{ value: null }`) while iOS forwards `NSNull`, creating inconsistent cross-platform behavior for the same React Native API call.
### Issue Context
- JS wrapper accepts `value: unknown` and forwards it as `{ value }` without validation.
- Android maps `ReadableType.Null` to `null` and now returns early.
- iOS forwards `NSNull` for missing/null values.
### Fix Focus Areas
- android/src/main/java/com/usercentrics/reactnative/RNUsercentricsModule.kt[150-160]
- android/src/main/java/com/usercentrics/reactnative/RNUsercentricsModule.kt[291-300]
- ios/RNUsercentricsModule.swift[153-156]
- src/Usercentrics.tsx[156-159]
### What to change
Choose and implement one consistent contract across platforms:
1) If `null` is intended to be supported: translate `null` to a non-null sentinel supported by the underlying Android SDK (and mirror that on iOS if needed), and still call `setGPPConsent`.
2) If `null` is not supported: add explicit validation (JS and/or native) to reject/log on `null` and ensure iOS does the same (don’t forward `NSNull` silently).

ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools



Advisory comments

2. 2.26.1 notes incomplete 🐞 Bug ⚙ Maintainability
Description
The 2.26.1 CHANGELOG entry lists several fixes but does not mention the React Native bridge changes
included in this PR (Android setGPPConsent null handling and the iOS Swift bridging type
annotation). This makes release notes incomplete for consumers tracking bridge/API behavior changes.
Code

CHANGELOG.md[R2-12]

+### 2.26.1 – Apr 07, 2026
+## Features
+* Added support for US National (GPP) privacy framework
+* Extended GPP API to Flutter, React Native and Unity bridges
+* Exposed DPS metadata via new `getDpsMetadata()` API
+* TCF resurfacing period now configurable via Admin UI (1–13 months)
+## Fixes
+* Fixed TCF resurfacing period logic
+* Fixed stored information not shown on DPS details
+* Fixed TCF maintain legitimate interest logic on Deny All
+
Evidence
The 2.26.1 changelog section includes only three fixes, while this PR also changes Android GPP
consent bridging behavior and adjusts iOS bridging code for GPP dictionary conversion; those changes
are not reflected in the release notes section.

CHANGELOG.md[1-12]
android/src/main/java/com/usercentrics/reactnative/RNUsercentricsModule.kt[150-160]
ios/Extensions/GppData+Dict.swift[8-22]

Agent prompt
The issue below was found during a code review. Follow the provided context and guidance below and implement a solution

## Issue description
The `CHANGELOG.md` entry for 2.26.1 does not include notable RN bridge changes shipped in this PR (Android `setGPPConsent` null handling behavior change; iOS GPP bridging adjustment), which can confuse SDK consumers.
### Issue Context
Release notes are the primary place users look to understand behavior changes and platform-specific fixes.
### Fix Focus Areas
- CHANGELOG.md[1-12]
### What to change
Add one or two bullets under `## Fixes` (or an appropriate subsection) describing the React Native bridge adjustments included in this release.

ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools


Grey Divider

ⓘ The new review experience is currently in Beta. Learn more

Grey Divider

Qodo Logo

@coderabbitai
Copy link
Copy Markdown

coderabbitai bot commented Apr 6, 2026

Note

Reviews paused

It looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the reviews.auto_review.auto_pause_after_reviewed_commits setting.

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.

Use the checkboxes below for quick actions:

  • ▶️ Resume reviews
  • 🔍 Trigger review

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 21056f1a-4a3e-4f1b-8f88-fad8d582dbb1

📥 Commits

Reviewing files that changed from the base of the PR and between ce39488 and 33fd871.

📒 Files selected for processing (2)
  • sample/ios/sampleTests/Fake/FakeUsercentricsManager.swift
  • src/models/TCF2Settings.tsx
✅ Files skipped from review due to trivial changes (1)
  • sample/ios/sampleTests/Fake/FakeUsercentricsManager.swift
🚧 Files skipped from review as they are similar to previous changes (1)
  • src/models/TCF2Settings.tsx

📝 Walkthrough

Walkthrough

Added release 2.26.1 notes and bumped package/Android SDK versions; documented US National (GPP) support, expanded GPP bridge coverage and added getDpsMetadata(), made TCF resurface period configurable, normalized GPP null handling in RN bridge, adjusted Swift bridging, and updated tests/mocks for vendor LI decisions.

Changes

Cohort / File(s) Summary
Release Documentation
CHANGELOG.md
Added release entry for 2.26.1 (US National GPP support, expanded bridges, getDpsMetadata(), configurable TCF resurface, and fixes).
Build & Package Versions
android/build-legacy.gradle, android/build.gradle.kts, package.json
Bumped Usercentrics SDK / package version 2.25.12.26.1.
React Native Android Bridge
android/src/main/java/com/usercentrics/reactnative/RNUsercentricsModule.kt
Normalize GPP consent values: replace JSON null with org.json.JSONObject.NULL before calling setGPPConsent.
Android CMP Serialization Helpers
android/src/main/java/.../UsercentricsCMPDataExtensions.kt
Added reflection-based helpers and serialized new fields: gppSignalingEnabled, gpcSignalHonoured, mspaCoveredTransaction, mspaMode; replaced resurfacePeriodEnded with resurfacePeriod compatibility logic.
iOS Bridging Utilities
ios/Extensions/GppData+Dict.swift, ios/Extensions/UsercentricsCMPData+Dict.swift
Added explicit closure types and nested-array casting in bridgeValue; extended toDictionary() outputs to include gppSignalingEnabled, gpcSignalHonoured, mspaCoveredTransaction, mspaMode, and resurfacePeriod.
Type / Model Updates (JS/TS)
src/models/UsercentricsSettings.tsx, src/models/CCPASettings.tsx, src/models/TCF2Settings.tsx
Added gppSignalingEnabled and gpcSignalHonoured to UsercentricsSettings; added mspaCoveredTransaction and mspaMode to CCPASettings; changed TCF2 resurfacePeriodEnded: booleanresurfacePeriod: number.
Tests & Mocks (iOS & JS)
sample/ios/sampleTests/Fake/FakeUsercentricsManager.swift, sample/ios/sampleTests/RNUsercentricsModuleTests.swift, sample/ios/sampleTests/Mock/CMPData+Mock.swift, src/__tests__/mocks.ts
Extended denyAllForTCF signature to accept unsavedVendorLIDecisions, added corresponding fake manager property, updated tests to pass vendor LI decisions, updated mocks to include new GPP/TCF fields, and updated test fixture resurfacePeriod.

Sequence Diagram(s)

sequenceDiagram
    participant AppJS as App (JS)
    participant RNBridge as RN Bridge
    participant NativeSDK as Native SDK
    participant DPS as DPS / Metadata

    AppJS->>RNBridge: call setGPPConsent(section, field, value)
    RNBridge->>RNBridge: normalize null -> JSONObject.NULL
    RNBridge->>NativeSDK: call setGPPConsent(section, field, normalizedValue)
    NativeSDK->>DPS: persist GPP consent / update DPS metadata
    NativeSDK->>RNBridge: emit onGppSectionChange / ack
    RNBridge->>AppJS: resolve promise / emit event
Loading

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

Possibly related PRs

Suggested labels

Review effort 1/5, size:M

Suggested reviewers

  • uc-brunosouza
  • islameldesoky95

Poem

🐰 A tiny hop for code and tea,

Nulls now safe in bridges' tree,
GPP sings across each shore,
DPS whispers metadata more,
Tests refreshed — release: whee! 🥕

🚥 Pre-merge checks | ✅ 2 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title 'Release: 2.26.1' clearly and concisely identifies the primary change—a version release bump—and accurately reflects the changeset's primary objective.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch bump/2.26.1

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@codeant-ai codeant-ai bot added the size:S This PR changes 10-29 lines, ignoring generated files label Apr 6, 2026
@pantoaibot
Copy link
Copy Markdown

pantoaibot bot commented Apr 6, 2026

PR Summary:

Release 2.26.1: adds GPP (US National) support, exposes GPP APIs across bridges, adds DPS metadata API, updates TCF resurfacing config, and includes several bug fixes; package and Android/iOS version bumps.

  • CHANGELOG: Added 2.26.1 release notes (features: US National GPP, extended GPP API to Flutter/React Native/Unity, getDpsMetadata(); fixes: TCF resurfacing logic, DPS details stored info, TCF LI on Deny All).
  • Version bumps: usercentrics version updated to 2.26.1 in android gradle files and package.json (including iosPackageVersion).
  • React Native Android module (RNUsercentricsModule.kt): tightened setGPPConsent to guard against null parsed values (parsedValue ?: return) to avoid passing null into setGPPConsent.
  • iOS bridging (GppData+Dict.swift): adjusted nested array mapping closure signature (nestedArray.map { nestedItem -> Any in ... }) to ensure correct type inference/bridging of nested values.
  • No breaking API changes detected in code diffs; changes are additive (new APIs/features) and bug fixes.

Reviewed by Panto AI

@pantoaibot
Copy link
Copy Markdown

pantoaibot bot commented Apr 6, 2026

Reviewed up to commit:533a373d4f11116a52ba6951d03b1eef263fe6c0

Reviewed by Panto AI


Few more points:

  • [CRITICAL_BUG] You changed behavior to return early when the incoming value is explicitly null (added parsedValue ?: return). That makes Android silently ignore explicit nulls while iOS passes NSNull/explicit value through (see ios RNUsercentricsModule.swift implementation in reference lines 138-150). This introduces platform-inconsistent behavior for setGPPConsent and can break consumers expecting parity. Actionable options (pick one):
  1. Make the native API accept nullable values and pass null explicitly to the manager (preferred for parity). Change the manager signature to accept a nullable Any (or Optional) and handle null inside the manager. Example: setGPPConsent(sectionName: String, fieldName: String, value: Any?) and then call usercentricsProxy.instance.setGPPConsent(sectionName, fieldName, parsedValue) (allowing parsedValue to be null).

  2. If null must be rejected, return a deterministic failure (log or raise JS exception) instead of silently returning. At minimum log a warning so it's not silently dropped.

  3. If you want to emulate iOS behavior, map JS null to a sentinel (e.g. JSONObject.NULL) and document that across platforms.

Also add a unit/integration test to assert cross-platform parity for setGPPConsent with null/NSNull values. Reference: RNUsercentricsModule.kt behavior around getGPP* / setGPPConsent in reference lines 136-173.

@ReactMethod
override fun setGPPConsent(sectionName: String, fieldName: String, value: ReadableMap) {
    if (!value.hasKey("value")) return

    val parsedValue: Any? = if (value.getType("value") == ReadableType.Null) {
        null
    } else {
        readableMapValueToAny(value)
    }

    // Option 1: propagate explicit nulls to the native SDK, keeping parity with iOS
    usercentricsProxy.instance.setGPPConsent(sectionName, fieldName, parsedValue)
}

@codeant-ai
Copy link
Copy Markdown

codeant-ai bot commented Apr 6, 2026

CodeAnt AI finished reviewing your PR.

Copy link
Copy Markdown

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
android/src/main/java/com/usercentrics/reactnative/RNUsercentricsModule.kt (1)

151-160: ⚠️ Potential issue | 🟠 Major

Platform behavior inconsistency: iOS lacks null guard in setGPPConsent.

The Android implementation correctly prevents null values from reaching the SDK with the null guard on line 158 (parsedValue ?: return). However, the iOS implementation at ios/RNUsercentricsModule.swift:153-156 always calls the SDK—passing NSNull() when the value is null or missing:

  • Android: Silently returns without calling SDK when parsedValue is null
  • iOS: Always calls SDK with either the actual value or NSNull()

This creates inconsistent cross-platform behavior for the same JavaScript input. Align the implementations by either adding a null check to iOS or documenting why the platforms intentionally differ.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@android/src/main/java/com/usercentrics/reactnative/RNUsercentricsModule.kt`
around lines 151 - 160, The iOS implementation of setGPPConsent in
RNUsercentricsModule.swift should match Android's behavior by preventing
null/NSNull from being passed to the SDK; update the setGPPConsent method to
parse the incoming value (the same way Android uses readableMapValueToAny
analog), check if the parsed value is nil (or is NSNull) and return early if so,
and only call usercentricsProxy.instance.setGPPConsent(...) when the parsed
value is non-nil, thereby avoiding passing NSNull() to the SDK and aligning
platform behavior with the Android setGPPConsent logic.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Outside diff comments:
In `@android/src/main/java/com/usercentrics/reactnative/RNUsercentricsModule.kt`:
- Around line 151-160: The iOS implementation of setGPPConsent in
RNUsercentricsModule.swift should match Android's behavior by preventing
null/NSNull from being passed to the SDK; update the setGPPConsent method to
parse the incoming value (the same way Android uses readableMapValueToAny
analog), check if the parsed value is nil (or is NSNull) and return early if so,
and only call usercentricsProxy.instance.setGPPConsent(...) when the parsed
value is non-nil, thereby avoiding passing NSNull() to the SDK and aligning
platform behavior with the Android setGPPConsent logic.

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: df910f9f-2131-47b2-8c57-ab6019889e27

📥 Commits

Reviewing files that changed from the base of the PR and between f45a517 and 533a373.

⛔ Files ignored due to path filters (3)
  • legacy-sample/package-lock.json is excluded by !**/package-lock.json
  • package-lock.json is excluded by !**/package-lock.json
  • sample/ios/Podfile.lock is excluded by !**/*.lock
📒 Files selected for processing (6)
  • CHANGELOG.md
  • android/build-legacy.gradle
  • android/build.gradle.kts
  • android/src/main/java/com/usercentrics/reactnative/RNUsercentricsModule.kt
  • ios/Extensions/GppData+Dict.swift
  • package.json

uc-brunosilva and others added 3 commits April 6, 2026 17:57
Co-authored-by: codeant-ai[bot] <151821869+codeant-ai[bot]@users.noreply.github.com>
…rTCF protocol signature

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Copy link
Copy Markdown

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🧹 Nitpick comments (1)
sample/ios/sampleTests/RNUsercentricsModuleTests.swift (1)

320-343: LGTM with optional improvement suggestion.

The test correctly passes the new unsavedVendorLIDecisions parameter. For more thorough verification, consider asserting that both LI decisions parameters are captured correctly by the fake:

,

✨ Optional: Add assertions for LI decisions parameters
       XCTAssertEqual(.explicit_, self.fakeUsercentrics.denyAllForTCFConsentType!)
       XCTAssertEqual(.firstLayer, self.fakeUsercentrics.denyAllForTCFFromLayer!)
+      XCTAssertEqual([:], self.fakeUsercentrics.denyAllForTCFUnsavedPurposeLIDecisions!)
+      XCTAssertEqual([:], self.fakeUsercentrics.denyAllForTCFUnsavedVendorLIDecisions!)
     } reject: { _, _, _ in
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@sample/ios/sampleTests/RNUsercentricsModuleTests.swift` around lines 320 -
343, The test testDenyAllForTCF currently exercises module.denyAllForTCF with
non-empty unsavedVendorLIDecisions but doesn't assert that the module forwarded
the LI decision parameters to the fake; update the test to assert that
fakeUsercentrics recorded the unsavedPurposeLIDecisions and
unsavedVendorLIDecisions fields (e.g., compare
fakeUsercentrics.lastDenyAllForTCFPurposeLIDecisions and
fakeUsercentrics.lastDenyAllForTCFVendorLIDecisions or whatever properties the
fake uses) match the arrays passed into module.denyAllForTCF, ensuring both LI
parameters are validated alongside the existing consent assertions.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Nitpick comments:
In `@sample/ios/sampleTests/RNUsercentricsModuleTests.swift`:
- Around line 320-343: The test testDenyAllForTCF currently exercises
module.denyAllForTCF with non-empty unsavedVendorLIDecisions but doesn't assert
that the module forwarded the LI decision parameters to the fake; update the
test to assert that fakeUsercentrics recorded the unsavedPurposeLIDecisions and
unsavedVendorLIDecisions fields (e.g., compare
fakeUsercentrics.lastDenyAllForTCFPurposeLIDecisions and
fakeUsercentrics.lastDenyAllForTCFVendorLIDecisions or whatever properties the
fake uses) match the arrays passed into module.denyAllForTCF, ensuring both LI
parameters are validated alongside the existing consent assertions.

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 9d700b67-a2ba-4889-a868-265eeba14a29

📥 Commits

Reviewing files that changed from the base of the PR and between 533a373 and bfa4439.

📒 Files selected for processing (4)
  • android/src/main/java/com/usercentrics/reactnative/RNUsercentricsModule.kt
  • ios/Extensions/GppData+Dict.swift
  • sample/ios/sampleTests/Fake/FakeUsercentricsManager.swift
  • sample/ios/sampleTests/RNUsercentricsModuleTests.swift
🚧 Files skipped from review as they are similar to previous changes (2)
  • android/src/main/java/com/usercentrics/reactnative/RNUsercentricsModule.kt
  • ios/Extensions/GppData+Dict.swift

uc-brunosilva and others added 3 commits April 6, 2026 18:37
Add gppSignalingEnabled/gpcSignalHonoured to UsercentricsSettings mock,
metadata to UsercentricsService/ServiceConsentTemplate mocks,
and mspaCoveredTransaction/mspaMode to CCPASettings mock.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- DisposableEvent.callback removed; use init(callback:) instead
- TCF2Settings.resurfacePeriodEnded renamed to resurfacePeriod (Int32)

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- TCF2Settings: resurfacePeriodEnded (bool) renamed to resurfacePeriod (int)
- CCPASettings: add mspaCoveredTransaction, mspaMode
- UsercentricsSettings: add gppSignalingEnabled, gpcSignalHonoured
- Update iOS/Android serializers and TypeScript models

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Copy link
Copy Markdown

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
src/models/TCF2Settings.tsx (1)

159-159: ⚠️ Potential issue | 🔴 Critical

Constructor assignment references non-existent property resurfacePeriodEnded.

The property and parameter were renamed from resurfacePeriodEnded to resurfacePeriod, but the constructor assignment at line 159 still uses the old name. This causes the TypeScript compilation error (TS2564) and leaves this.resurfacePeriod uninitialized.

🐛 Proposed fix
-        this.resurfacePeriodEnded = resurfacePeriodEnded
+        this.resurfacePeriod = resurfacePeriod
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@src/models/TCF2Settings.tsx` at line 159, The constructor in class
TCF2Settings assigns to the old property name resurfacePeriodEnded which no
longer exists; update the constructor to assign the incoming parameter to the
correct property name resurfacePeriod (ensure the constructor parameter is named
resurfacePeriod or rename it accordingly) so that this.resurfacePeriod is
initialized; locate the assignment in the TCF2Settings constructor and replace
the reference to resurfacePeriodEnded with resurfacePeriod.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Outside diff comments:
In `@src/models/TCF2Settings.tsx`:
- Line 159: The constructor in class TCF2Settings assigns to the old property
name resurfacePeriodEnded which no longer exists; update the constructor to
assign the incoming parameter to the correct property name resurfacePeriod
(ensure the constructor parameter is named resurfacePeriod or rename it
accordingly) so that this.resurfacePeriod is initialized; locate the assignment
in the TCF2Settings constructor and replace the reference to
resurfacePeriodEnded with resurfacePeriod.

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: e8df7d59-bd9c-42d8-bd1b-b0a4cac1a739

📥 Commits

Reviewing files that changed from the base of the PR and between 7f42c65 and ce39488.

📒 Files selected for processing (6)
  • android/src/main/java/com/usercentrics/reactnative/extensions/UsercentricsCMPDataExtensions.kt
  • ios/Extensions/UsercentricsCMPData+Dict.swift
  • src/__tests__/mocks.ts
  • src/models/CCPASettings.tsx
  • src/models/TCF2Settings.tsx
  • src/models/UsercentricsSettings.tsx
✅ Files skipped from review due to trivial changes (1)
  • src/models/CCPASettings.tsx

uc-brunosilva and others added 2 commits April 6, 2026 19:22
…uctor

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…nullable type

UsercentricsDisposableEvent.init(callback:) now expects ((T?) -> Void)? in 2.26.1.
Wrap the non-optional callback to handle the optional payload parameter.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:S This PR changes 10-29 lines, ignoring generated files

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants