/
githubmirror
/
gitness
Обзор
Документация
Войти
/
githubmirror
/
gitness
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
main
web/src/utils/SessionToken.ts
15 строк
728 B
Ritik Kapoor
chore: [CODE-5159] Stop using session/local storage for auth tokens (#5170)
10 апр 2026, 12:45
10 апр 2026, 12:45
c1f56a0
Код
Авторство
О чём код?
/* * Copyright 2023 Harness Inc. All rights reserved. * Use of this source code is governed by the PolyForm Shield 1.0.0 license * that can be found in the licenses directory at the root of this repository, also available at * https://polyformproject.org/wp-content/uploads/2020/06/PolyForm-Shield-1.0.0.txt. */ import SecureStorage from './SecureStorage' export default { username: (): string => SecureStorage.get<string>('username') || '', accountId: (): string => SecureStorage.get<string>('acctId') || '', getLastTokenSetTime: (): number | undefined => SecureStorage.get<number>('lastTokenSetTime'), getSessionTimeOutInMinutes: (): number | undefined => SecureStorage.get<number>('sessionTimeOutInMinutes') }