function social_like_invalidate_cache in Open Social 8
Same name and namespace in other branches
- 8.9 modules/social_features/social_like/social_like.module \social_like_invalidate_cache()
- 8.2 modules/social_features/social_like/social_like.module \social_like_invalidate_cache()
- 8.3 modules/social_features/social_like/social_like.module \social_like_invalidate_cache()
- 8.4 modules/social_features/social_like/social_like.module \social_like_invalidate_cache()
- 8.5 modules/social_features/social_like/social_like.module \social_like_invalidate_cache()
- 8.6 modules/social_features/social_like/social_like.module \social_like_invalidate_cache()
- 8.7 modules/social_features/social_like/social_like.module \social_like_invalidate_cache()
- 8.8 modules/social_features/social_like/social_like.module \social_like_invalidate_cache()
- 10.3.x modules/social_features/social_like/social_like.module \social_like_invalidate_cache()
- 10.0.x modules/social_features/social_like/social_like.module \social_like_invalidate_cache()
- 10.1.x modules/social_features/social_like/social_like.module \social_like_invalidate_cache()
- 10.2.x modules/social_features/social_like/social_like.module \social_like_invalidate_cache()
Implements social_like_invalidate_cache().
2 calls to social_like_invalidate_cache()
- social_like_entity_delete in modules/
social_features/ social_like/ social_like.module - Implements hook_entity_delete().
- social_like_entity_insert in modules/
social_features/ social_like/ social_like.module - Implements hook_entity_insert().
File
- modules/
social_features/ social_like/ social_like.module, line 60 - The social_like module.
Code
function social_like_invalidate_cache(EntityInterface $entity) {
$cache_tag = [
$entity
->getEntityTypeId() . ':' . $entity
->id(),
'config:views.view.who_liked_this_entity',
];
Cache::invalidateTags($cache_tag);
}