From edd808f124f4ada99bcbe4bca98ddbe20e5a424c Mon Sep 17 00:00:00 2001 From: bufubaoni Date: Thu, 2 Nov 2023 16:02:51 +0800 Subject: [PATCH] fix: avoid the front-end calling api/renew loop (#2792) --- http/auth.go | 1 + 1 file changed, 1 insertion(+) diff --git a/http/auth.go b/http/auth.go index 4df68262..75c66149 100644 --- a/http/auth.go +++ b/http/auth.go @@ -173,6 +173,7 @@ var signupHandler = func(w http.ResponseWriter, r *http.Request, d *data) (int, } var renewHandler = withUser(func(w http.ResponseWriter, r *http.Request, d *data) (int, error) { + w.Header().Set("X-Renew-Token", "false") return printToken(w, r, d, d.user) })