mirror of
https://github.com/usememos/memos.git
synced 2024-12-19 17:12:02 +03:00
fix: session max age (#392)
This commit is contained in:
parent
2a275b2875
commit
55dee0df7e
@ -25,7 +25,7 @@ func setUserSession(ctx echo.Context, user *api.User) error {
|
||||
sess, _ := session.Get("session", ctx)
|
||||
sess.Options = &sessions.Options{
|
||||
Path: "/",
|
||||
MaxAge: 1000 * 3600 * 24 * 30,
|
||||
MaxAge: 3600 * 24 * 30,
|
||||
HttpOnly: true,
|
||||
}
|
||||
sess.Values[userIDContextKey] = user.ID
|
||||
|
Loading…
Reference in New Issue
Block a user