user comment cached with user_id as well

This commit is contained in:
Umputun
2019-04-07 18:38:06 -05:00
parent 078bedd8e8
commit 22d787de58
+1 -1
View File
@@ -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 {