-
Notifications
You must be signed in to change notification settings - Fork 2.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Native: privacyLink is now converted to ortb.privacy #10271
Changes from 2 commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -480,6 +480,11 @@ export function toOrtbNativeRequest(legacyNativeAssets) { | |
continue; | ||
} | ||
|
||
if (key === 'privacyLink') { | ||
ortb.privacy = 1; | ||
continue; | ||
} | ||
|
||
const asset = legacyNativeAssets[key]; | ||
let required = 0; | ||
if (asset.required && isBoolean(asset.required)) { | ||
|
@@ -623,6 +628,9 @@ export function fromOrtbNativeRequest(openRTBRequest) { | |
oldNativeObject[prebidAssetName].len = asset.data.len; | ||
} | ||
} | ||
if (openRTBRequest.privacy) { | ||
oldNativeObject.privacyLink = { required: false }; | ||
} | ||
// video was not supported by old prebid assets | ||
} | ||
return oldNativeObject; | ||
|
@@ -696,8 +704,11 @@ export function legacyPropertiesToOrtbNative(legacyNative) { | |
// in general, native trackers seem to be neglected and/or broken | ||
response.jstracker = Array.isArray(value) ? value.join('') : value; | ||
break; | ||
case 'privacyLink': | ||
response.privacy = 1; | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Shouldn't this value be a string of the URL that the adapters return for the old There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Yeah you are definitely right ---- |
||
break; | ||
} | ||
}) | ||
}); | ||
return response; | ||
} | ||
|
||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If I say
privacyLink: {required: false}
should this still be set to 1?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
in ORTB the flag signals support and not whether the link is required, so maybe this is OK - but we should set
required: false
in the inverse logic?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
My takes on this
I'd say the presence of the attribute means that you'd like to set privacy to 1.
Agree, will fix