Skip to content

Commit

Permalink
fix(session): set inactivity timeout to 2 hours and max sessions to 3…
Browse files Browse the repository at this point in the history
… (before it was 30min and 2 sessions)
  • Loading branch information
aleksasiriski committed Jan 1, 2025
1 parent 2989bf7 commit fdab102
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/lib/server/db/session.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ import { sessionTable, type Session } from './schema/session';
import { DB as db } from './connect';
import { env } from '$env/dynamic/private';

export const inactivityTimeout = Number.parseInt(env.INACTIVITY_TIMEOUT ?? '30') * 60 * 1000;
export const maxActiveSessions = Number.parseInt(env.MAX_ACTIVE_SESSIONS ?? '2');
export const inactivityTimeout = Number.parseInt(env.INACTIVITY_TIMEOUT ?? '120') * 60 * 1000;
export const maxActiveSessions = Number.parseInt(env.MAX_ACTIVE_SESSIONS ?? '3');

export function generateSessionToken(): string {
const bytes = new Uint8Array(20);
Expand Down

0 comments on commit fdab102

Please sign in to comment.