diff --git a/core/modules/menu_link_content/lib/Drupal/menu_link_content/Plugin/Menu/MenuLinkContent.php b/core/modules/menu_link_content/lib/Drupal/menu_link_content/Plugin/Menu/MenuLinkContent.php index a594748..6b4b20d 100644 --- a/core/modules/menu_link_content/lib/Drupal/menu_link_content/Plugin/Menu/MenuLinkContent.php +++ b/core/modules/menu_link_content/lib/Drupal/menu_link_content/Plugin/Menu/MenuLinkContent.php @@ -101,6 +101,7 @@ protected function getEntity() { if (!$this->entity) { throw new PluginException("Invalid entity ID or uuid"); } + $this->entity = $this->entityManager->getTranslationFromContext($this->entity); $this->entity->setInsidePlugin(); } return $this->entity; diff --git a/core/modules/system/lib/Drupal/system/Plugin/Block/SystemMenuBlock.php b/core/modules/system/lib/Drupal/system/Plugin/Block/SystemMenuBlock.php index fa4c086..01ccca8 100644 --- a/core/modules/system/lib/Drupal/system/Plugin/Block/SystemMenuBlock.php +++ b/core/modules/system/lib/Drupal/system/Plugin/Block/SystemMenuBlock.php @@ -115,7 +115,7 @@ public function getCacheTags() { protected function getRequiredCacheContexts() { // Menu blocks must be cached per role: different roles may have access to // different menu links. - return array('cache_context.user.roles', 'cache_context.url'); + return array('cache_context.user.roles', 'cache_context.url', 'cache_context.language'); } }