X-Git-Url: http://www.aleph1.co.uk/gitweb/?p=yaffs-website;a=blobdiff_plain;f=web%2Fmodules%2Fcontrib%2Fentity%2Fsrc%2FPlugin%2FAction%2FDeleteAction.php;fp=web%2Fmodules%2Fcontrib%2Fentity%2Fsrc%2FPlugin%2FAction%2FDeleteAction.php;h=c99d4c9ecdbe2cf0963df04bbc40223c63baaca0;hp=d61983d43e73b51bcc52ed0676f3124eb6e07a84;hb=af6d1fb995500ae68849458ee10d66abbdcfb252;hpb=680c79a86e3ed402f263faeac92e89fb6d9edcc0 diff --git a/web/modules/contrib/entity/src/Plugin/Action/DeleteAction.php b/web/modules/contrib/entity/src/Plugin/Action/DeleteAction.php index d61983d43..c99d4c9ec 100644 --- a/web/modules/contrib/entity/src/Plugin/Action/DeleteAction.php +++ b/web/modules/contrib/entity/src/Plugin/Action/DeleteAction.php @@ -5,7 +5,7 @@ namespace Drupal\entity\Plugin\Action; use Drupal\Core\Action\ActionBase; use Drupal\Core\Plugin\ContainerFactoryPluginInterface; use Drupal\Core\Session\AccountInterface; -use Drupal\user\PrivateTempStoreFactory; +use Drupal\Core\TempStore\PrivateTempStoreFactory; use Symfony\Component\DependencyInjection\ContainerInterface; /** @@ -22,7 +22,7 @@ class DeleteAction extends ActionBase implements ContainerFactoryPluginInterface /** * The tempstore object. * - * @var \Drupal\user\SharedTempStore + * @var \Drupal\Core\TempStore\SharedTempStore */ protected $tempStore; @@ -42,7 +42,7 @@ class DeleteAction extends ActionBase implements ContainerFactoryPluginInterface * The plugin ID for the plugin instance. * @param mixed $plugin_definition * The plugin implementation definition. - * @param \Drupal\user\PrivateTempStoreFactory $temp_store_factory + * @param \Drupal\Core\TempStore\PrivateTempStoreFactory $temp_store_factory * The tempstore factory. * @param AccountInterface $current_user * Current user. @@ -62,7 +62,7 @@ class DeleteAction extends ActionBase implements ContainerFactoryPluginInterface $configuration, $plugin_id, $plugin_definition, - $container->get('user.private_tempstore'), + $container->get('tempstore.private'), $container->get('current_user') ); } @@ -71,13 +71,13 @@ class DeleteAction extends ActionBase implements ContainerFactoryPluginInterface * {@inheritdoc} */ public function executeMultiple(array $entities) { - /** @var \Drupal\Core\Entity\ContentEntityInterface[] $entities */ + /** @var \Drupal\Core\Entity\EntityInterface[] $entities */ $selection = []; foreach ($entities as $entity) { $langcode = $entity->language()->getId(); $selection[$entity->id()][$langcode] = $langcode; } - $this->tempStore->set($this->currentUser->id(), $selection); + $this->tempStore->set($this->currentUser->id() . ':' . $this->getPluginDefinition()['type'], $selection); } /**