mirror of
https://github.com/usememos/memos.git
synced 2025-03-05 01:53:14 +08:00
fix: session max age (#392)
This commit is contained in:
parent
2a275b2875
commit
55dee0df7e
1 changed files with 1 additions and 1 deletions
|
@ -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 a new issue