20c20 < index 6f246f7..8c66b5a 100644 --- > index c2a0214..e33b0bc 100644 23c23 < @@ -18,6 +18,7 @@ --- > @@ -19,6 +19,7 @@ 28c28 < use Drupal\field\Entity\FieldConfig; --- > use Drupal\field\Entity\FieldStorageConfig; 31c31 < @@ -105,6 +106,13 @@ class ContentEntityDatabaseStorage extends ContentEntityStorageBase implements S --- > @@ -106,6 +107,13 @@ class ContentEntityDatabaseStorage extends ContentEntityStorageBase implements S 45,46c45 < @@ -118,7 +126,8 @@ public static function createInstance(ContainerInterface $container, EntityTypeI < return new static( --- > @@ -127,6 +135,7 @@ public static function createInstance(ContainerInterface $container, EntityTypeI 49,51c48,50 < - $container->get('entity.manager') < + $container->get('entity.manager'), < + $container->get('language_manager') --- > $container->get('entity.manager'), > + $container->get('language_manager'), > $container->get('cache.entity') 54,55c53 < < @@ -142,12 +151,15 @@ public function getFieldStorageDefinitions() { --- > @@ -151,15 +160,18 @@ public function getFieldStorageDefinitions() { 60a59,60 > * @param \Drupal\Core\Cache\CacheBackendInterface $cache_backend > * The cache backend to be used. 62,63c62,63 < - public function __construct(EntityTypeInterface $entity_type, Connection $database, EntityManagerInterface $entity_manager) { < + public function __construct(EntityTypeInterface $entity_type, Connection $database, EntityManagerInterface $entity_manager, LanguageManagerInterface $language_manager) { --- > - public function __construct(EntityTypeInterface $entity_type, Connection $database, EntityManagerInterface $entity_manager, CacheBackendInterface $cache) { > + public function __construct(EntityTypeInterface $entity_type, Connection $database, EntityManagerInterface $entity_manager, LanguageManagerInterface $language_manager, CacheBackendInterface $cache) { 67a68 > $this->cacheBackend = $cache; 72c73 < @@ -960,7 +972,7 @@ protected function doLoadFieldItems($entities, $age) { --- > @@ -1139,7 +1151,7 @@ protected function loadFieldItems(array $entities) { 227c228 < index 945ff9d..1752c77 100644 --- > index 2d5541e..55f6b00 100644 230c231 < @@ -12,6 +12,7 @@ --- > @@ -14,6 +14,7 @@ 238c239 < @@ -46,13 +47,15 @@ class CommentStorage extends ContentEntityDatabaseStorage implements CommentStor --- > @@ -48,6 +49,8 @@ class CommentStorage extends ContentEntityDatabaseStorage implements CommentStor 243a245,246 > * @param \Drupal\Core\Cache\CacheBackendInterface $cache_backend > * Cache backend instance to use. 245c248 < * The comment statistics service. --- > @@ -55,8 +58,8 @@ class CommentStorage extends ContentEntityDatabaseStorage implements CommentStor 249,252c252,255 < - public function __construct(EntityTypeInterface $entity_info, Connection $database, EntityManagerInterface $entity_manager, CommentStatisticsInterface $comment_statistics, AccountInterface $current_user) { < - parent::__construct($entity_info, $database, $entity_manager); < + public function __construct(EntityTypeInterface $entity_info, Connection $database, EntityManagerInterface $entity_manager, LanguageManagerInterface $language_manager, CommentStatisticsInterface $comment_statistics, AccountInterface $current_user) { < + parent::__construct($entity_info, $database, $entity_manager, $language_manager); --- > - public function __construct(EntityTypeInterface $entity_info, Connection $database, EntityManagerInterface $entity_manager, CommentStatisticsInterface $comment_statistics, AccountInterface $current_user, CacheBackendInterface $cache) { > - parent::__construct($entity_info, $database, $entity_manager, $cache); > + public function __construct(EntityTypeInterface $entity_info, Connection $database, EntityManagerInterface $entity_manager, LanguageManagerInterface $language_manager, CommentStatisticsInterface $comment_statistics, AccountInterface $current_user, CacheBackendInterface $cache) { > + parent::__construct($entity_info, $database, $entity_manager, $language_manager, $cache); 256c259 < @@ -65,6 +68,7 @@ public static function createInstance(ContainerInterface $container, EntityTypeI --- > @@ -69,6 +72,7 @@ public static function createInstance(ContainerInterface $container, EntityTypeI 262,263c265,266 < $container->get('current_user') < ); --- > $container->get('current_user'), > $container->get('cache.entity') 292c295 < index 10c5f25..a1136cc 100644 --- > index 791ef85..ec6fe13 100644 642c645 < index c678554..d849cca 100644 --- > index ad3543b..8a2fbcc 100644 645c648 < @@ -294,7 +294,7 @@ public function query($use_groupby = FALSE) { --- > @@ -297,7 +297,7 @@ public function query($use_groupby = FALSE) { 654c657 < @@ -901,7 +901,7 @@ protected function addSelfTokens(&$tokens, $item) { --- > @@ -914,7 +914,7 @@ protected function addSelfTokens(&$tokens, $item) { 664c667 < index 97fa6ff..4d4e4d4 100644 --- > index ce63484..52d9132 100644 667c670 < @@ -1017,7 +1017,7 @@ function file_tokens($type, $tokens, array $data = array(), array $options = arr --- > @@ -1018,7 +1018,7 @@ function file_tokens($type, $tokens, array $data = array(), array $options = arr 950,962d952 < diff --git a/core/modules/language/src/Plugin/views/field/LanguageField.php b/core/modules/language/src/Plugin/views/field/LanguageField.php < index 3909fcd..9d9e27d 100644 < --- a/core/modules/language/src/Plugin/views/field/LanguageField.php < +++ b/core/modules/language/src/Plugin/views/field/LanguageField.php < @@ -43,7 +43,7 @@ public function render(ResultRow $values) { < // @todo: Drupal Core dropped native language until config translation is < // ready, see http://drupal.org/node/1616594. < $value = $this->getValue($values); < - $language = language_load($value); < + $language = \Drupal::languageManager()->getLanguage($value); < return $language ? $language->name : ''; < } < 964c954 < index c846026..b8f6de4 100644 --- > index c01accb..4e23fb0 100644 977c967 < index e0e4ac2..7b431d1 100644 --- > index d86027b..c167fa2 100644 990c980 < index eeccaa8..ea161aa 100644 --- > index cbe9d1a..f9c8350 100644 993c983 < @@ -88,7 +88,7 @@ public function getTranslation($langcode) { --- > @@ -90,7 +90,7 @@ public function getTranslation($langcode) { 1029c1019 < index 3409383..a99b792 100644 --- > index f8e76a8..ba8a429 100644 1032c1022 < @@ -15,6 +15,7 @@ --- > @@ -16,6 +16,7 @@ 1040c1030 < @@ -113,6 +114,7 @@ static public function create(ContainerInterface $container, array $configuratio --- > @@ -114,6 +115,7 @@ static public function create(ContainerInterface $container, array $configuratio 1048c1038 < @@ -133,6 +135,8 @@ static public function create(ContainerInterface $container, array $configuratio --- > @@ -134,6 +136,8 @@ static public function create(ContainerInterface $container, array $configuratio 1057c1047 < @@ -142,9 +146,10 @@ static public function create(ContainerInterface $container, array $configuratio --- > @@ -143,9 +147,10 @@ static public function create(ContainerInterface $container, array $configuratio 1069c1059 < @@ -273,7 +278,7 @@ public function execute() { --- > @@ -276,7 +281,7 @@ public function execute() { 1118c1108 < index 8ff4b54..2f4b363 100644 --- > index 350869b..547ffb3 100644 1219c1209 < index 44d323f..db5ceba 100644 --- > index 3a9d9f5..2b3301c 100644 1222c1212 < @@ -11,6 +11,7 @@ --- > @@ -12,6 +12,7 @@ 1230c1220 < @@ -47,13 +48,15 @@ class UserStorage extends ContentEntityDatabaseStorage implements UserStorageInt --- > @@ -41,13 +42,15 @@ class UserStorage extends ContentEntityDatabaseStorage implements UserStorageInt 1235a1226,1227 > * @param \Drupal\Core\Cache\CacheBackendInterface $cache_backend > * Cache backend instance to use. 1238,1239d1229 < * @param \Drupal\user\UserDataInterface $user_data < * The user data service. 1241,1244c1231,1234 < - public function __construct(EntityTypeInterface $entity_type, Connection $database, EntityManagerInterface $entity_manager, PasswordInterface $password, UserDataInterface $user_data) { < - parent::__construct($entity_type, $database, $entity_manager); < + public function __construct(EntityTypeInterface $entity_type, Connection $database, EntityManagerInterface $entity_manager, LanguageManagerInterface $language_manager, PasswordInterface $password, UserDataInterface $user_data) { < + parent::__construct($entity_type, $database, $entity_manager, $language_manager); --- > - public function __construct(EntityTypeInterface $entity_type, Connection $database, EntityManagerInterface $entity_manager, CacheBackendInterface $cache, PasswordInterface $password) { > - parent::__construct($entity_type, $database, $entity_manager, $cache); > + public function __construct(EntityTypeInterface $entity_type, Connection $database, EntityManagerInterface $entity_manager, LanguageManagerInterface $language_manager, CacheBackendInterface $cache, PasswordInterface $password) { > + parent::__construct($entity_type, $database, $entity_manager, $language_manager, $cache); 1247,1248c1237,1238 < $this->userData = $user_data; < @@ -67,6 +70,7 @@ public static function createInstance(ContainerInterface $container, EntityTypeI --- > } > @@ -60,6 +63,7 @@ public static function createInstance(ContainerInterface $container, EntityTypeI 1253,1254c1243,1244 < $container->get('password'), < $container->get('user.data') --- > $container->get('cache.entity'), > $container->get('password') 1257c1247 < index 288a84b..9e0ce1e 100644 --- > index 3d3d6a5..8252f9b 100644 1260c1250 < @@ -1256,7 +1256,7 @@ public function optionsSummary(&$categories, &$options) { --- > @@ -1250,7 +1250,7 @@ public function optionsSummary(&$categories, &$options) { 1270c1260 < index 6d5e3fa..8265f1e 100644 --- > index 1ba7c23..ba6778f 100644 1283c1273 < index 960f735..4f2d7a1 100644 --- > index 849d063..20a3120 100644 1286c1276 < @@ -47,6 +47,13 @@ class ContentEntityDatabaseStorageTest extends UnitTestCase { --- > @@ -50,6 +50,13 @@ class ContentEntityDatabaseStorageTest extends UnitTestCase { 1297,1301c1287,1291 < * {@inheritdoc} < */ < public function setUp() { < @@ -56,6 +63,8 @@ public function setUp() { < ->will($this->returnValue('entity_test')); --- > * The entity type ID. > * > * @var string > @@ -97,6 +104,7 @@ public function setUp() { > \Drupal::setContainer($this->container); 1304d1293 < + 1306,1309c1295,1298 < } < < /** < @@ -1039,7 +1048,7 @@ protected function setUpEntityStorage() { --- > $this->moduleHandler = $this->getMock('Drupal\Core\Extension\ModuleHandlerInterface'); > $this->cache = $this->getMock('Drupal\Core\Cache\CacheBackendInterface'); > $this->connection = $this->getMockBuilder('Drupal\Core\Database\Connection') > @@ -1080,7 +1088,7 @@ protected function setUpEntityStorage() { 1313,1314c1302,1303 < - $this->entityStorage = new ContentEntityDatabaseStorage($this->entityType, $connection, $this->entityManager); < + $this->entityStorage = new ContentEntityDatabaseStorage($this->entityType, $connection, $this->entityManager, $this->languageManager); --- > - $this->entityStorage = new ContentEntityDatabaseStorage($this->entityType, $this->connection, $this->entityManager, $this->cache); > + $this->entityStorage = new ContentEntityDatabaseStorage($this->entityType, $this->connection, $this->entityManager, $this->languageManager, $this->cache); 1317c1306,1324 < } --- > /** > @@ -1157,7 +1165,7 @@ public function testLoadMultipleNoPersistentCache() { > ->method('set'); > > $entity_storage = $this->getMockBuilder('Drupal\Core\Entity\ContentEntityDatabaseStorage') > - ->setConstructorArgs(array($this->entityType, $this->connection, $this->entityManager, $this->cache)) > + ->setConstructorArgs(array($this->entityType, $this->connection, $this->entityManager, $this->languageManager, $this->cache)) > ->setMethods(array('getFromStorage')) > ->getMock(); > $entity_storage->expects($this->once()) > @@ -1207,7 +1215,7 @@ public function testLoadMultiplePersistentCacheMiss() { > ->with($key, $entity, CacheBackendInterface::CACHE_PERMANENT, array($this->entityTypeId . '_values' => TRUE, 'entity_field_info' => TRUE)); > > $entity_storage = $this->getMockBuilder('Drupal\Core\Entity\ContentEntityDatabaseStorage') > - ->setConstructorArgs(array($this->entityType, $this->connection, $this->entityManager, $this->cache)) > + ->setConstructorArgs(array($this->entityType, $this->connection, $this->entityManager, $this->languageManager, $this->cache)) > ->setMethods(array('getFromStorage')) > ->getMock(); > $entity_storage->expects($this->once())