fix: avoid the front-end calling api/renew loop (#2792)

This commit is contained in:
bufubaoni 2023-11-02 16:02:51 +08:00 committed by GitHub
parent cdcd9a313a
commit edd808f124
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 0 deletions

View File

@ -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)
})