diff options
author | Chris <ccbrown112@gmail.com> | 2017-09-14 12:01:44 -0500 |
---|---|---|
committer | Harrison Healey <harrisonmhealey@gmail.com> | 2017-09-14 13:01:44 -0400 |
commit | b6fb98a43176215f16fc52b64abebde51355e5c1 (patch) | |
tree | 095a2006bdfdd30d1a9c4fc4e604924fc0f50225 /store/local_cache_supplier_reactions.go | |
parent | af81f7e48bd2afaaa8c71f78bf86bdc00b104e4d (diff) | |
download | chat-b6fb98a43176215f16fc52b64abebde51355e5c1.tar.gz chat-b6fb98a43176215f16fc52b64abebde51355e5c1.tar.bz2 chat-b6fb98a43176215f16fc52b64abebde51355e5c1.zip |
remove more global references (#7442)
Diffstat (limited to 'store/local_cache_supplier_reactions.go')
-rw-r--r-- | store/local_cache_supplier_reactions.go | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/store/local_cache_supplier_reactions.go b/store/local_cache_supplier_reactions.go index 102215941..a67cff2e4 100644 --- a/store/local_cache_supplier_reactions.go +++ b/store/local_cache_supplier_reactions.go @@ -18,23 +18,23 @@ func (s *LocalCacheSupplier) handleClusterInvalidateReaction(msg *model.ClusterM } func (s *LocalCacheSupplier) ReactionSave(ctx context.Context, reaction *model.Reaction, hints ...LayeredStoreHint) *LayeredStoreSupplierResult { - doInvalidateCacheCluster(s.reactionCache, reaction.PostId) + s.doInvalidateCacheCluster(s.reactionCache, reaction.PostId) return s.Next().ReactionSave(ctx, reaction, hints...) } func (s *LocalCacheSupplier) ReactionDelete(ctx context.Context, reaction *model.Reaction, hints ...LayeredStoreHint) *LayeredStoreSupplierResult { - doInvalidateCacheCluster(s.reactionCache, reaction.PostId) + s.doInvalidateCacheCluster(s.reactionCache, reaction.PostId) return s.Next().ReactionDelete(ctx, reaction, hints...) } func (s *LocalCacheSupplier) ReactionGetForPost(ctx context.Context, postId string, hints ...LayeredStoreHint) *LayeredStoreSupplierResult { - if result := doStandardReadCache(ctx, s.reactionCache, postId, hints...); result != nil { + if result := s.doStandardReadCache(ctx, s.reactionCache, postId, hints...); result != nil { return result } result := s.Next().ReactionGetForPost(ctx, postId, hints...) - doStandardAddToCache(ctx, s.reactionCache, postId, result, hints...) + s.doStandardAddToCache(ctx, s.reactionCache, postId, result, hints...) return result } @@ -42,6 +42,6 @@ func (s *LocalCacheSupplier) ReactionGetForPost(ctx context.Context, postId stri func (s *LocalCacheSupplier) ReactionDeleteAllWithEmojiName(ctx context.Context, emojiName string, hints ...LayeredStoreHint) *LayeredStoreSupplierResult { // This could be improved. Right now we just clear the whole // cache because we don't have a way find what post Ids have this emoji name. - doClearCacheCluster(s.reactionCache) + s.doClearCacheCluster(s.reactionCache) return s.Next().ReactionDeleteAllWithEmojiName(ctx, emojiName, hints...) } |