Skip to content

🐛 Fix client hints URL parameter construction in mapp_intelligence#40523

Open
StephanGuenther wants to merge 1 commit into
ampproject:mainfrom
StephanGuenther:main
Open

🐛 Fix client hints URL parameter construction in mapp_intelligence#40523
StephanGuenther wants to merge 1 commit into
ampproject:mainfrom
StephanGuenther:main

Conversation

@StephanGuenther

Copy link
Copy Markdown
Contributor

The previous implementation used separate variables for parameter names (uachModelParam) and values (uachModelValue), assembled in clientHintParams with a hardcoded & separator. When client hints were disabled, this produced malformed URL fragments like &= in the tracking request.

This change consolidates the six variables into three segment variables (uachModelSegment, uachPlatformSegment, uachPlatformVersionSegment) that each include the &KEY="VALUE" unit as a whole — the & separator is now inside the $IF condition and only appears when the value is actually present.

The test expectations in vendor-requests.json are updated accordingly.

Consolidate separate param-name and value variables into single segment
variables that include the & separator only when the value is present,
preventing malformed &= fragments in the tracking URL when client hints
are disabled.

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

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant