From c21b42f6f3e0ee350dd18f5168b470ff251717bd Mon Sep 17 00:00:00 2001 From: Steve Hanlon Date: Thu, 9 Jul 2026 08:14:42 +0100 Subject: [PATCH] Grant full consent fallback for non-TCF visitors in bridge mode (v1.3.3) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Visitors outside EEA/UK/CH (e.g. Americas) have no __tcfapi injected by Google Funding Choices, causing the TCF bridge poll to time out and leaving them permanently at the default denied state. After the 10s timeout, grant full consent — GDPR opt-in doesn't apply to these visitors and CCPA is an opt-out model, so granted is the correct default. Co-Authored-By: Claude Sonnet 4.6 --- att-consent.php | 4 ++-- public/js/tcf-bridge.js | 6 ++++++ 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/att-consent.php b/att-consent.php index 639d9d0..fc429d0 100644 --- a/att-consent.php +++ b/att-consent.php @@ -3,7 +3,7 @@ * Plugin Name: ATT Consent * Plugin URI: https://github.com/att-consent/att-consent * Description: Google Consent Mode v2 cookie consent with session attribution preservation, custom script management, and full gtag.js/GTM support. - * Version: 1.3.2 + * Version: 1.3.3 * Requires at least: 6.0 * Requires PHP: 7.4 * Author: ATT Consent @@ -18,7 +18,7 @@ if ( ! defined( 'ABSPATH' ) ) { exit; } -define( 'ATT_CC_VERSION', '1.3.2' ); +define( 'ATT_CC_VERSION', '1.3.3' ); define( 'ATT_CC_PLUGIN_DIR', plugin_dir_path( __FILE__ ) ); define( 'ATT_CC_PLUGIN_URL', plugin_dir_url( __FILE__ ) ); define( 'ATT_CC_PLUGIN_BASENAME', plugin_basename( __FILE__ ) ); diff --git a/public/js/tcf-bridge.js b/public/js/tcf-bridge.js index 16aef3c..28dc8ae 100644 --- a/public/js/tcf-bridge.js +++ b/public/js/tcf-bridge.js @@ -91,6 +91,12 @@ } elapsed += POLL_INTERVAL; if (elapsed >= MAX_WAIT_MS) { + // __tcfapi never appeared: visitor is outside TCF jurisdiction (e.g. Americas) + // or the CMP script was blocked. GDPR opt-in doesn't apply; grant full consent + // so these visitors aren't silently tracked as denied. + try { + window.AttConsent.update({ functional: true, analytics: true, marketing: true }); + } catch (e) {} return; } setTimeout(poll, POLL_INTERVAL);