The cust_param handing in getCustParams() func in modules/gamAdServerVideo.js uses src/util formatQS() which handles arrays explicitly with PHP-style bracket notation. This converts custom KV pairs, which needs to be sent to GAM, like below:
From:
bidders_enabled: ['ix', 'rubicon']
to
bidders_enabled[]=ix&bidders_enabled[]=rubicon
causing reporting mismatch in GAM.
I can see that this func was added in this commit along with func parseQS (which does the opposite and removes the [])
I see only 2 consumers feed formatQS() a raw JS array and trigger k[]=v output:
- gamAdServerVideo.js where the issue is happening
- adlooxAnalyticsAdapter.js where i see a comment addressing the issue.
- modules/adlooxRtdProvider.js - which uses buildUrl(internally uses formatQS) and then strips the []
I can also see that libraries/medianetUtils/utils.js has pivoted to use its own formatQS definition.
The cust_param handing in getCustParams() func in modules/gamAdServerVideo.js uses src/util formatQS() which handles arrays explicitly with PHP-style bracket notation. This converts custom KV pairs, which needs to be sent to GAM, like below:
From:
bidders_enabled: ['ix', 'rubicon']to
bidders_enabled[]=ix&bidders_enabled[]=rubiconcausing reporting mismatch in GAM.
I can see that this func was added in this commit along with func parseQS (which does the opposite and removes the [])
I see only 2 consumers feed formatQS() a raw JS array and trigger k[]=v output:
I can also see that libraries/medianetUtils/utils.js has pivoted to use its own formatQS definition.