We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 73aa6cd commit 4962688Copy full SHA for 4962688
1 file changed
packages/server/api/src/app/authentication/context/authentication-cookies.ts
@@ -11,11 +11,11 @@ import { getSubDomain } from '../../helper/sub-domain';
11
export function setAuthCookies(
12
reply: FastifyReply,
13
response: AuthenticationResponse,
14
- expireInSeconds?: number,
+ expiresAt?: number,
15
): FastifyReply {
16
let cookieExpiryDate: Date;
17
- if (expireInSeconds) {
18
- cookieExpiryDate = new Date(expireInSeconds * 1000);
+ if (expiresAt) {
+ cookieExpiryDate = new Date(expiresAt * 1000);
19
} else {
20
const date = jwtDecode<{ exp: number }>(response.tablesRefreshToken);
21
cookieExpiryDate = new Date(date.exp * 1000);
0 commit comments