Skip to content

Commit

Permalink
cookies are declined by default
Browse files Browse the repository at this point in the history
  • Loading branch information
alishaevn committed Nov 29, 2023
1 parent 5cea42d commit e66cd8c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions utils/cookies.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ const cookieConsentGiven = hasCookie('_dl_cookie_consent')

export const getCookieConsent = () => !cookieConsentGiven

export const cookieConsentValue = cookieConsentGiven ? getCookie('_dl_cookie_consent') : 'true'
export const cookieConsentValue = cookieConsentGiven ? getCookie('_dl_cookie_consent') : 'false'

/**
* setting the maxAge means that the cookie will be "deleted" after the maxAge has passed.
Expand Down Expand Up @@ -41,6 +41,6 @@ const nonEssentialCookies = [
]

export const disableCookies = () => {
nonEssentialCookies.forEach(cookie => deleteCookie(cookie))
// nonEssentialCookies.forEach(cookie => deleteCookie(cookie))
setCookie('_dl_cookie_consent', 'false', cookieOptions)
}

0 comments on commit e66cd8c

Please sign in to comment.