Skip to content

Commit

Permalink
fix(backport): exclude utm_term from collection
Browse files Browse the repository at this point in the history
The utm_term is typically populated from search queries and can theoretically leak PII. So it's safest to exclude it from collection for now

Fix #153
  • Loading branch information
ramboz authored Apr 18, 2024
2 parents 564a674 + af9d77f commit 7a5e5b2
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -195,6 +195,7 @@ new PerformanceObserver((list) => {
[...new URLSearchParams(window.location.search).entries()]
.filter(([key]) => key.startsWith('utm_'))
.filter(([key]) => key !== 'utm_id')
.filter(([key]) => key !== 'utm_term')
.forEach(([key, value]) => {
sampleRUM('utm', { source: key, target: value });
});

0 comments on commit 7a5e5b2

Please sign in to comment.