/**
  * {@inheritdoc}
  */
 public function getCacheContexts()
 {
     $contexts = parent::getCacheContexts();
     // Node access is potentially cacheable per user.
     $contexts[] = 'cache.context.user';
     return $contexts;
 }
Example #2
0
 /**
  * {@inheritdoc}
  */
 public function getCacheContexts()
 {
     $contexts = parent::getCacheContexts();
     $contexts[] = 'user.node_grants:view';
     return $contexts;
 }
Example #3
0
 /**
  * {@inheritdoc}
  */
 public function getCacheContexts()
 {
     $contexts = parent::getCacheContexts();
     $contexts[] = 'user';
     return $contexts;
 }
 /**
  * {@inheritdoc}
  */
 public function getCacheContexts()
 {
     $cache_contexts = parent::getCacheContexts();
     $cache_contexts[] = 'views_test_cache_context';
     return $cache_contexts;
 }