From 38f40a154bb67878e9e21dab43a104f421392515 Mon Sep 17 00:00:00 2001 From: GoEdgeLab Date: Tue, 12 Dec 2023 22:28:17 +0800 Subject: [PATCH] =?UTF-8?q?=E5=88=87=E6=8D=A2=E8=AF=AD=E8=A8=80=E6=97=B6?= =?UTF-8?q?=E4=BF=9D=E5=AD=98=E6=9B=B4=E9=95=BF=E6=97=B6=E9=97=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- internal/web/actions/default/settings/lang/switch.go | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/internal/web/actions/default/settings/lang/switch.go b/internal/web/actions/default/settings/lang/switch.go index 7ed7f033..008ff7a4 100644 --- a/internal/web/actions/default/settings/lang/switch.go +++ b/internal/web/actions/default/settings/lang/switch.go @@ -24,9 +24,10 @@ func (this *SwitchAction) RunPost(params struct{}) { } this.AddCookie(&http.Cookie{ - Name: "edgelang", - Value: langCode, - Path: "/", + Name: "edgelang", + Value: langCode, + Path: "/", + MaxAge: 86400 * 365, }) this.Success()