Skip to content

Commit

Permalink
Merge pull request #2231 from prince-deriv/update-cookie-v1.0.1
Browse files Browse the repository at this point in the history
  • Loading branch information
Nuzhy-Deriv authored Nov 27, 2024
2 parents ff1076f + 8ad80ca commit 448973f
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions public/scripts/cookie/v1.0.1.js
Original file line number Diff line number Diff line change
Expand Up @@ -217,11 +217,11 @@ const shouldOverwrite = (new_utm_data, current_utm_data) => {
/* end handling date first contact */

/* start handling gclid */
const gclid = searchParams.has("gclid")
const gclid_url = searchParams.has("gclid_url")
const final_gclid = gclid || gclid_url
if (final_gclid) {
const gclid = searchParams.get("gclid");
const gclid_url = searchParams.get("gclid_url");
const final_gclid = gclid || gclid_url || "";

if (!!final_gclid) {
eraseCookie("gclid");
document.cookie = `gclid=${final_gclid};domain=${getDomain()}; path=/; SameSite=None; Secure;`;
}
Expand Down

0 comments on commit 448973f

Please sign in to comment.