feat: Enahnce add item delay

This commit is contained in:
Jose Selesan
2026-10-19 12:26:21 -03:00
parent 815dcc300d
commit c374db1616
4 changed files with 73 additions and 6 deletions

View File

@@ -14,6 +14,15 @@ export const auth = betterAuth({
baseURL: process.env.BETTER_AUTH_URL,
secret: process.env.BETTER_AUTH_SECRET,
trustedOrigins,
session: {
// A signed copy of the session lives in a cookie for 5 minutes, so protected
// routes skip the session lookup in Postgres on every request. Trade-off: a
// session revoked elsewhere stays valid on other devices until the cache expires.
cookieCache: {
enabled: true,
maxAge: 5 * 60,
},
},
emailAndPassword: {
enabled: true,
minPasswordLength: 8,