Remove check for deprecated FLoC opt-out

This commit is contained in:
nisbet-hubbard 2025-07-19 20:53:26 +08:00 committed by GitHub
parent c7f7941de2
commit 45d325755f
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -448,38 +448,6 @@ define([
});
}
assert(function (cb, msg) {
setWarningClass(msg);
var printMessage = function (value) {
msg.appendChild(h('span', [
"This instance hasn't opted out of participation in Google's ",
code('FLoC'),
" targeted advertizing network. ",
"This can be done by setting a ",
code('permissions-policy'),
" HTTP header with a value of ",
code('"interest-cohort=()"'),
" in the configuration of its reverse proxy instead of the current value (",
code(value),
"). See the provided NGINX configuration file for an example. ",
h('p', [
link("https://www.eff.org/deeplinks/2021/04/am-i-floced-launch", 'Learn more'),
]),
]));
};
Tools.common_xhr('/', function (xhr) {
var header = xhr.getResponseHeader('permissions-policy') || '';
var rules = header.split(',');
if (rules.includes('interest-cohort=()')) { return void cb(true); }
printMessage(JSON.stringify(header));
cb(header);
});
});
assert(function (cb, msg) {
msg.appendChild(h('span', [
code('/api/broadcast'),