diff --git a/core/modules/forum/lib/Drupal/forum/Form/Overview.php b/core/modules/forum/lib/Drupal/forum/Form/Overview.php index d31387c..b79bbfd 100644 --- a/core/modules/forum/lib/Drupal/forum/Form/Overview.php +++ b/core/modules/forum/lib/Drupal/forum/Form/Overview.php @@ -35,7 +35,7 @@ class Overview extends OverviewTerms { * The module handler service. */ public function __construct(EntityManagerInterface $entity_manager, ModuleHandlerInterface $module_handler) { - parent::__construct($module_handler); + parent::__construct($module_handler, $entity_manager); $this->entityManager = $entity_manager; } diff --git a/core/modules/taxonomy/lib/Drupal/taxonomy/Entity/Term.php b/core/modules/taxonomy/lib/Drupal/taxonomy/Entity/Term.php index 5a7e6fd..de0388e 100644 --- a/core/modules/taxonomy/lib/Drupal/taxonomy/Entity/Term.php +++ b/core/modules/taxonomy/lib/Drupal/taxonomy/Entity/Term.php @@ -151,10 +151,10 @@ public static function postDelete(EntityStorageControllerInterface $storage_cont // See if any of the term's children are about to be become orphans. $orphans = array(); foreach (array_keys($entities) as $tid) { - if ($children = taxonomy_term_load_children($tid)) { + if ($children = $storage_controller->loadChildren($tid)) { foreach ($children as $child) { // If the term has multiple parents, we don't delete it. - $parents = taxonomy_term_load_parents($child->id()); + $parents = $storage_controller->loadParents($child->id()); if (empty($parents)) { $orphans[] = $child->id(); } diff --git a/core/modules/taxonomy/lib/Drupal/taxonomy/TermStorageController.php b/core/modules/taxonomy/lib/Drupal/taxonomy/TermStorageController.php index 1f1802b..b88e1fc 100644 --- a/core/modules/taxonomy/lib/Drupal/taxonomy/TermStorageController.php +++ b/core/modules/taxonomy/lib/Drupal/taxonomy/TermStorageController.php @@ -99,6 +99,12 @@ protected function buildPropertyQuery(QueryInterface $entity_query, array $value */ public function resetCache(array $ids = NULL) { drupal_static_reset('taxonomy_term_count_nodes'); + $this->parents = array(); + $this->parentsAll = array(); + $this->children = array(); + $this->treeChildren = array(); + $this->treeParents = array(); + $this->treeTerms = array(); parent::resetCache($ids); } diff --git a/core/modules/taxonomy/lib/Drupal/taxonomy/Tests/TaxonomyTermIndentationTest.php b/core/modules/taxonomy/lib/Drupal/taxonomy/Tests/TaxonomyTermIndentationTest.php index 5020cc2..44c4ee3 100644 --- a/core/modules/taxonomy/lib/Drupal/taxonomy/Tests/TaxonomyTermIndentationTest.php +++ b/core/modules/taxonomy/lib/Drupal/taxonomy/Tests/TaxonomyTermIndentationTest.php @@ -72,7 +72,7 @@ function testTermIndentation() { $this->assertNoPattern('|