diff --git a/src/Form/DeleteMultiple.php b/src/Form/DeleteMultiple.php index 9ed6a2c..68ecd45 100644 --- a/src/Form/DeleteMultiple.php +++ b/src/Form/DeleteMultiple.php @@ -12,7 +12,7 @@ use Drupal\Core\Url; use Drupal\Component\Utility\String; use Drupal\Core\Form\FormStateInterface; -use Drupal\user\TempStoreFactory; +use Drupal\user\PrivateTempStoreFactory; use Symfony\Component\HttpFoundation\RedirectResponse; use Symfony\Component\DependencyInjection\ContainerInterface; @@ -31,7 +31,7 @@ class DeleteMultiple extends ConfirmFormBase { /** * The tempstore factory. * - * @var \Drupal\user\TempStoreFactory + * @var \Drupal\user\PrivateTempStoreFactory */ protected $tempStoreFactory; @@ -45,12 +45,12 @@ class DeleteMultiple extends ConfirmFormBase { /** * Constructs a DeleteMultiple form object. * - * @param \Drupal\user\TempStoreFactory $temp_store_factory - * The tempstore factory. + * @param \Drupal\user\PrivateTempStoreFactory $temp_store_factory + * The factory for the temp store object. * @param \Drupal\Core\Entity\EntityManagerInterface $manager * The entity manager. */ - public function __construct(TempStoreFactory $temp_store_factory, EntityManagerInterface $manager) { + public function __construct(PrivateTempStoreFactory $temp_store_factory, EntityManagerInterface $manager) { $this->tempStoreFactory = $temp_store_factory; $this->storage = $manager->getStorage('profile'); } @@ -60,7 +60,7 @@ public function __construct(TempStoreFactory $temp_store_factory, EntityManagerI */ public static function create(ContainerInterface $container) { return new static( - $container->get('user.tempstore'), + $container->get('user.private_tempstore'), $container->get('entity.manager') ); } diff --git a/src/Plugin/Action/DeleteProfile.php b/src/Plugin/Action/DeleteProfile.php index ddd5552..78fa846 100644 --- a/src/Plugin/Action/DeleteProfile.php +++ b/src/Plugin/Action/DeleteProfile.php @@ -10,7 +10,7 @@ use Drupal\Core\Action\ActionBase; use Drupal\Core\Plugin\ContainerFactoryPluginInterface; use Drupal\Core\Session\AccountInterface; -use Drupal\user\TempStoreFactory; +use Drupal\user\PrivateTempStoreFactory; use Symfony\Component\DependencyInjection\ContainerInterface; /** @@ -26,9 +26,9 @@ class DeleteProfile extends ActionBase implements ContainerFactoryPluginInterface { /** - * The tempstore object. + * The tempstore factory. * - * @var \Drupal\user\TempStore + * @var \Drupal\user\PrivateTempStoreFactory */ protected $tempStore; @@ -41,10 +41,10 @@ class DeleteProfile extends ActionBase implements ContainerFactoryPluginInterfac * The plugin ID for the plugin instance. * @param mixed $plugin_definition * The plugin implementation definition. - * @param \Drupal\user\TempStoreFactory $temp_store_factory + * @param \Drupal\user\PrivateTempStoreFactory $temp_store_factory * The tempstore factory. */ - public function __construct(array $configuration, $plugin_id, $plugin_definition, TempStoreFactory $temp_store_factory) { + public function __construct(array $configuration, $plugin_id, $plugin_definition, PrivateTempStoreFactory $temp_store_factory) { parent::__construct($configuration, $plugin_id, $plugin_definition); $this->tempStore = $temp_store_factory->get('profile_multiple_delete_confirm'); @@ -54,7 +54,7 @@ public function __construct(array $configuration, $plugin_id, $plugin_definition * {@inheritdoc} */ public static function create(ContainerInterface $container, array $configuration, $plugin_id, $plugin_definition) { - return new static($configuration, $plugin_id, $plugin_definition, $container->get('user.tempstore')); + return new static($configuration, $plugin_id, $plugin_definition, $container->get('user.private_tempstore')); } /** diff --git a/src/Tests/ProfileAccessTest.php b/src/Tests/ProfileAccessTest.php index 14272ee..686c37e 100644 --- a/src/Tests/ProfileAccessTest.php +++ b/src/Tests/ProfileAccessTest.php @@ -18,7 +18,7 @@ */ class ProfileAccessTest extends WebTestBase { - public static $modules = array('profile', 'text'); + public static $modules = array('profile', 'text', 'user'); function setUp() { parent::setUp(); diff --git a/src/Tests/ProfileAttachTest.php b/src/Tests/ProfileAttachTest.php index c1a9f9d..225c463 100644 --- a/src/Tests/ProfileAttachTest.php +++ b/src/Tests/ProfileAttachTest.php @@ -18,7 +18,7 @@ */ class ProfileAttachTest extends WebTestBase { - public static $modules = array('profile', 'text'); + public static $modules = array('profile', 'text', 'user'); function setUp() { parent::setUp(); diff --git a/src/Tests/ProfileFieldAccessTest.php b/src/Tests/ProfileFieldAccessTest.php index ad2fc16..a1d64df 100644 --- a/src/Tests/ProfileFieldAccessTest.php +++ b/src/Tests/ProfileFieldAccessTest.php @@ -16,7 +16,7 @@ */ class ProfileFieldAccessTest extends WebTestBase { - public static $modules = array('profile', 'text', 'field_ui'); + public static $modules = array('profile', 'text', 'field_ui', 'user'); function setUp() { parent::setUp(); diff --git a/src/Tests/ProfileTypeCRUDTest.php b/src/Tests/ProfileTypeCRUDTest.php index a0620cb..40e4465 100644 --- a/src/Tests/ProfileTypeCRUDTest.php +++ b/src/Tests/ProfileTypeCRUDTest.php @@ -17,7 +17,7 @@ */ class ProfileTypeCRUDTest extends WebTestBase { - public static $modules = array('profile', 'field_ui', 'text'); + public static $modules = array('profile', 'field_ui', 'text', 'user'); /** * Tests CRUD operations for profile types through the UI.