Skip to content

Commit

Permalink
Fix not stripping referrer query string in all cases
Browse files Browse the repository at this point in the history
  • Loading branch information
benvinegar committed Jun 15, 2024
1 parent 405c228 commit fb021bf
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions public/tracker.js
Original file line number Diff line number Diff line change
Expand Up @@ -128,12 +128,11 @@ SOFTWARE.

// only set referrer if not internal
let referrer = vars.referrer || "";
// strip query string from referrer
referrer = referrer.split("?")[0];

if (document.referrer.indexOf(hostname) < 0) {
referrer = document.referrer;
}
// strip query string from referrer
referrer = referrer.split("?")[0];

const d = {
p: path,
Expand Down

0 comments on commit fb021bf

Please sign in to comment.