Add secure: true
This commit is contained in:
parent
457368180f
commit
1f42a0f661
1 changed files with 4 additions and 2 deletions
|
@ -24,7 +24,8 @@ export const setUser = (user, expiryDate, options = {}) => {
|
||||||
}
|
}
|
||||||
Cookies.set('user', user, {
|
Cookies.set('user', user, {
|
||||||
expires: differenceInDays(expiryDate, new Date()),
|
expires: differenceInDays(expiryDate, new Date()),
|
||||||
sameSite: 'Lax',
|
sameSite: 'None',
|
||||||
|
secure: true,
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -35,7 +36,8 @@ export const setAuthCredentials = response => {
|
||||||
const expiryDate = getHeaderExpiry(response);
|
const expiryDate = getHeaderExpiry(response);
|
||||||
Cookies.set('auth_data', response.headers, {
|
Cookies.set('auth_data', response.headers, {
|
||||||
expires: differenceInDays(expiryDate, new Date()),
|
expires: differenceInDays(expiryDate, new Date()),
|
||||||
sameSite: 'Lax',
|
sameSite: 'None',
|
||||||
|
secure: true,
|
||||||
});
|
});
|
||||||
setUser(response.data.data, expiryDate);
|
setUser(response.data.data, expiryDate);
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in a new issue