Support from Acquia helps fund testing for Drupal Acquia logo

Comments

rocket.man created an issue. See original summary.

bkhandruk’s picture

Assigned: bkhandruk » Unassigned
Status: Active » Needs review
FileSize
4.22 KB

Replaced uses of deprecated EntityManagerInterface.

hgunicamp’s picture

Status: Needs review » Reviewed & tested by the community

I tested the patch and it worked for me.

cit008490cpsubuntu:taxonomy_menu progestag* 8.x-3.x$ find .  -type f \( -name '*.php' -or -name '*.module' -or -name '*.yml' \) -exec grep -i --color=auto entitymanager {} \+
./src/TaxonomyMenuHelper.php:use Drupal\Core\Entity\EntityManagerInterface;
./src/TaxonomyMenuHelper.php:  public function __construct(EntityManagerInterface $entity_manager, MenuLinkManagerInterface $manager) {
./src/Plugin/Menu/TaxonomyMenuMenuLink.php:use Drupal\Core\Entity\EntityManagerInterface;
./src/Plugin/Menu/TaxonomyMenuMenuLink.php:   * @var \Drupal\Core\Entity\EntityManager
./src/Plugin/Menu/TaxonomyMenuMenuLink.php:  protected $entityManager;
./src/Plugin/Menu/TaxonomyMenuMenuLink.php:   * @param \Drupal\Core\Entity\EntityManagerInterface $entity_manager
./src/Plugin/Menu/TaxonomyMenuMenuLink.php:    EntityManagerInterface $entity_manager,
./src/Plugin/Menu/TaxonomyMenuMenuLink.php:    $this->entityManager = $entity_manager;
./src/Plugin/Menu/TaxonomyMenuMenuLink.php:    $link = $this->entityManager->getStorage('taxonomy_term')
./src/Plugin/Menu/TaxonomyMenuMenuLink.php:    $link = $this->entityManager->getStorage('taxonomy_term')

cit008490cpsubuntu:taxonomy_menu progestag* 8.x-3.x$ patch -p1 < ~/drupal/Patches/taxonomy_menu-replace_deprecated_entity_manager_interface_uses-2857550-2.patch
patching file src/Plugin/Menu/TaxonomyMenuMenuLink.php
patching file src/TaxonomyMenuHelper.php

cit008490cpsubuntu:taxonomy_menu progestag* 8.x-3.x$ find .  -type f \( -name '*.php' -or -name '*.module' -or -name '*.yml' \) -exec grep -i --color=auto entitymanager {} \+ | wc -l
0
Dinesh18’s picture

Reviewed the patch #2 and verified that EntityManager is replaced by EntityTypeManager.
+1 to RTBC

dstol’s picture

Status: Reviewed & tested by the community » Fixed

Thanks for the contribution!

  • dstol committed e01a5ff on 8.x-3.x authored by rocket.man
    Issue #2857550 by rocket.man: Replace deprecated EntityManagerInterface...

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.