refactor(index.html): update production tracking ID logic

- Simplified the logic for determining the production tracking ID by removing the check for the 'worklenz.com' hostname.
- Ensured that the tracking ID is now solely based on the 'app.worklenz.com' hostname, streamlining the analytics loading process.
This commit is contained in:
chamikaJ
2025-07-07 14:50:01 +05:30
parent 8533a440bc
commit 134899114d

View File

@@ -43,9 +43,7 @@
// Use requestIdleCallback to defer analytics loading
const loadAnalytics = () => {
// Determine which tracking ID to use based on the environment
const isProduction =
window.location.hostname === 'worklenz.com' ||
window.location.hostname === 'app.worklenz.com';
const isProduction = window.location.hostname === 'app.worklenz.com';
const trackingId = isProduction ? 'G-XXXXXXXXXX' : 'G-3LM2HGWEXG'; // Open source tracking ID