Skip to content

Commit

Permalink
Merge pull request #748 from wazo-platform/NES-2220-auto-logout
Browse files Browse the repository at this point in the history
[NES-2220] expiresAt valid in major browsers
  • Loading branch information
Romej authored Feb 19, 2024
2 parents a744222 + 3c3057b commit c008f26
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/domain/Session.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
/* eslint-disable no-nested-ternary */
import { KEYUTIL, KJUR, b64utoutf8 } from 'jsrsasign';
import moment from 'moment';
import swarmPublicKey from '../pubkey';
import Profile from './Profile';
import Contact from './Contact';
Expand Down Expand Up @@ -126,7 +127,7 @@ export default class Session {
authorizations,
acl: plain.data.acls ? plain.data.acls : plain.data.acl ? plain.data.acl : [],
tenantUuid: plain.data.metadata ? plain.data.metadata.tenant_uuid : undefined,
expiresAt: new Date(`${plain.data.utc_expires_at}z`),
expiresAt: moment.utc(plain.data.utc_expires_at).toDate(),
stackUuid: plain.data.xivo_uuid,
// eslint-disable-next-line
stackHostFromHeader: plain._headers?.get?.('wazo-stack-host'),
Expand Down

0 comments on commit c008f26

Please sign in to comment.