mirror of
https://github.com/nextcloud/server.git
synced 2026-06-10 09:13:19 -04:00
Merge pull request #53525 from nextcloud/chore/typo
chore(core): fix typo in session heartbeat service
This commit is contained in:
commit
40e536bf8b
2 changed files with 5 additions and 5 deletions
|
|
@ -23,7 +23,7 @@ interface OcJsConfig {
|
|||
const {
|
||||
auto_logout: autoLogout,
|
||||
session_keepalive: keepSessionAlive,
|
||||
session_lifetime: seesionLifetime,
|
||||
session_lifetime: sessionLifetime,
|
||||
} = loadState<Partial<OcJsConfig>>('core', 'config', {})
|
||||
|
||||
/**
|
||||
|
|
@ -76,8 +76,8 @@ export function initSessionHeartBeat() {
|
|||
* Get interval in seconds
|
||||
*/
|
||||
function getInterval(): number {
|
||||
const interval = seesionLifetime
|
||||
? Math.floor(seesionLifetime / 2)
|
||||
const interval = sessionLifetime
|
||||
? Math.floor(sessionLifetime / 2)
|
||||
: 900
|
||||
|
||||
// minimum one minute, max 24 hours, default 15 minutes
|
||||
|
|
@ -146,7 +146,7 @@ function registerAutoLogout() {
|
|||
|
||||
let intervalId = 0
|
||||
const logoutCheck = () => {
|
||||
const timeout = Date.now() - (seesionLifetime ?? 86400) * 1000
|
||||
const timeout = Date.now() - (sessionLifetime ?? 86400) * 1000
|
||||
if (lastActive < timeout) {
|
||||
clearTimeout(intervalId)
|
||||
logger.info('Inactivity timout reached, logging out')
|
||||
|
|
|
|||
2
dist/core-main.js.map
vendored
2
dist/core-main.js.map
vendored
File diff suppressed because one or more lines are too long
Loading…
Reference in a new issue