Disable caching of some GET apis. Closes #1530
This commit is contained in:
@@ -37,8 +37,6 @@ func GetChatMessages(w http.ResponseWriter, r *http.Request) {
|
||||
|
||||
// RegisterAnonymousChatUser will register a new user.
|
||||
func RegisterAnonymousChatUser(w http.ResponseWriter, r *http.Request) {
|
||||
w.Header().Set("Content-Type", "application/json")
|
||||
|
||||
if r.Method != POST {
|
||||
WriteSimpleResponse(w, false, r.Method+" not supported")
|
||||
return
|
||||
@@ -72,5 +70,8 @@ func RegisterAnonymousChatUser(w http.ResponseWriter, r *http.Request) {
|
||||
DisplayName: newUser.DisplayName,
|
||||
}
|
||||
|
||||
w.Header().Set("Content-Type", "application/json")
|
||||
middleware.DisableCache(w)
|
||||
|
||||
WriteResponse(w, response)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user