From 22d787de5829463ac2abdfb244a3a06b08013980 Mon Sep 17 00:00:00 2001 From: Umputun Date: Sun, 7 Apr 2019 18:38:06 -0500 Subject: [PATCH] user comment cached with user_id as well --- backend/app/rest/api/rest_public.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/backend/app/rest/api/rest_public.go b/backend/app/rest/api/rest_public.go index 815c400c..92f26ad5 100644 --- a/backend/app/rest/api/rest_public.go +++ b/backend/app/rest/api/rest_public.go @@ -186,7 +186,7 @@ func (s *Rest) findUserCommentsCtrl(w http.ResponseWriter, r *http.Request) { log.Printf("[DEBUG] get comments for userID %s, %s", userID, siteID) - key := cache.NewKey(siteID).ID(URLKey(r)).Scopes(userID, siteID) + key := cache.NewKey(siteID).ID(URLKeyWithUser(r)).Scopes(userID, siteID) data, err := s.Cache.Get(key, func() ([]byte, error) { comments, e := s.DataService.User(siteID, userID, limit, 0) if e != nil {