mirror of
https://git.crystalyx.net/Xefir/repod.git
synced 2024-12-26 16:55:13 +01:00
fix(cookie): 🔒 fix warning message on firefox console, make cookie strict
This commit is contained in:
parent
3ec978be7e
commit
227b3eb938
@ -24,5 +24,5 @@ export const getCookie = (name) => {
|
|||||||
export const setCookie = (name, value, days) => {
|
export const setCookie = (name, value, days) => {
|
||||||
const date = new Date()
|
const date = new Date()
|
||||||
date.setDate(date.getDate() + days)
|
date.setDate(date.getDate() + days)
|
||||||
document.cookie = `${name}=${encodeURIComponent(value)}; expires=${date.toUTCString()};`
|
document.cookie = `${name}=${encodeURIComponent(value)}; expires=${date.toUTCString()}; SameSite=Strict;`
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user