diff --git a/nodeorder.info.yml b/nodeorder.info.yml
index 5b021e7..a0e3502 100644
--- a/nodeorder.info.yml
+++ b/nodeorder.info.yml
@@ -1,6 +1,6 @@
 name: 'Node Order'
 description: 'Allows the ordering of nodes within taxonomy terms.'
-core: 8.x
+core_version_requirement: ^8 || ^9
 configure: nodeorder.admin
 dependencies:
   - drupal:node
diff --git a/nodeorder.install b/nodeorder.install
index fa397f4..c3d684c 100644
--- a/nodeorder.install
+++ b/nodeorder.install
@@ -5,6 +5,8 @@
  * Nodeorder install file.
  */
 
+use Drupal\Core\Database\Database;
+
 /**
  * Implements hook_install().
  *
@@ -28,7 +30,7 @@ function nodeorder_install() {
   $keys['fields']['weight'] = $spec;
 
   // Add the column to the table.
-  db_add_field('taxonomy_index', 'weight', $spec, $keys);
+  Database::getConnection()->schema()->addField('taxonomy_index', 'weight', $spec, $keys);
 
   // Set the weight of the nodeorder module ensure that nodeorder can alter
   // forms after the taxonomy module.
@@ -41,6 +43,6 @@ function nodeorder_install() {
  * Drops field 'weight' from core table 'taxonomy_index'.
  */
 function nodeorder_uninstall() {
-  db_drop_index('taxonomy_index', 'weight');
-  db_drop_field('taxonomy_index', 'weight');
+  Database::getConnection()->schema()->dropIndex('taxonomy_index', 'weight');
+  Database::getConnection()->schema()->dropField('taxonomy_index', 'weight');
 }
diff --git a/nodeorder.module b/nodeorder.module
index 25236f4..b8133ca 100755
--- a/nodeorder.module
+++ b/nodeorder.module
@@ -40,7 +40,7 @@ function nodeorder_entity_operation(EntityInterface $entity) {
   if ($entity instanceof Term) {
     /** @var \Drupal\nodeorder\NodeOrderManagerInterface $nodeorder_manager */
     $nodeorder_manager = \Drupal::service('nodeorder.manager');
-    if ($nodeorder_manager->vocabularyIsOrderable($entity->getVocabularyId())) {
+    if ($nodeorder_manager->vocabularyIsOrderable($entity->bundle())) {
       $operations['order'] = [
         'title' => t('Order'),
         'query' => \Drupal::destination()->getAsArray(),
diff --git a/nodeorder.services.yml b/nodeorder.services.yml
index a6729a1..54842fe 100755
--- a/nodeorder.services.yml
+++ b/nodeorder.services.yml
@@ -6,4 +6,4 @@ services:
 
   nodeorder.manager:
     class: Drupal\nodeorder\NodeOrderManager
-    arguments: ['@config.factory', '@entity.manager', '@cache.default']
+    arguments: ['@config.factory', '@entity_type.manager', '@cache.default']
diff --git a/src/Access/NodeOrderAccess.php b/src/Access/NodeOrderAccess.php
index c5b6b73..6505531 100644
--- a/src/Access/NodeOrderAccess.php
+++ b/src/Access/NodeOrderAccess.php
@@ -67,7 +67,7 @@ class NodeOrderAccess implements ContainerInjectionInterface {
    *   Access result.
    */
   public function isVocabularyOrderable(Term $taxonomy_term) {
-    $vocabulary_id = $taxonomy_term->getVocabularyId();
+    $vocabulary_id = $taxonomy_term->bundle();
 
     return $this->nodeOrderManager->vocabularyIsOrderable($vocabulary_id)
       ? AccessResult::allowed()
diff --git a/src/NodeOrderListBuilder.php b/src/NodeOrderListBuilder.php
index d180c79..f367d76 100644
--- a/src/NodeOrderListBuilder.php
+++ b/src/NodeOrderListBuilder.php
@@ -103,7 +103,7 @@ class NodeOrderListBuilder extends EntityListBuilder implements FormInterface {
   public static function createInstance(ContainerInterface $container, EntityTypeInterface $entity_type, Term $taxonomy_term = NULL) {
     return new static(
       $entity_type,
-      $container->get('entity.manager')->getStorage($entity_type->id()),
+      $container->get('entity_type.manager')->getStorage($entity_type->id()),
       $container->get('database'),
       $container->get('form_builder'),
       $container->get('cache_tags.invalidator'),
@@ -177,7 +177,7 @@ class NodeOrderListBuilder extends EntityListBuilder implements FormInterface {
     ];
 
     /** @var \Drupal\node\Entity\NodeType $type */
-    $type = $entity->type->entity;
+    $type = $entity->get('type')->entity;
     $row['type'] = ['#markup' => $type->label()];
 
     $published = $entity->isPublished() ? $this->t('Published') : $this->t('Not published');
diff --git a/src/NodeOrderManager.php b/src/NodeOrderManager.php
index 4dbc209..52e828c 100644
--- a/src/NodeOrderManager.php
+++ b/src/NodeOrderManager.php
@@ -6,7 +6,7 @@ use Drupal\Core\Cache\Cache;
 use Drupal\node\NodeInterface;
 use Drupal\taxonomy\Entity\Vocabulary;
 use Drupal\Core\Config\ConfigFactoryInterface;
-use Drupal\Core\Entity\EntityManagerInterface;
+use Drupal\Core\Entity\EntityTypeManagerInterface;
 use Drupal\Core\Cache\CacheBackendInterface;
 
 /**
@@ -40,12 +40,12 @@ class NodeOrderManager implements NodeOrderManagerInterface {
    *
    * @param \Drupal\Core\Config\ConfigFactoryInterface $config_factory
    *   The configuration object factory.
-   * @param \Drupal\Core\Entity\EntityManagerInterface $entity_manager
+   * @param \Drupal\Core\Entity\EntityTypeManagerInterface $entity_manager
    *   The entity manager.
    * @param \Drupal\Core\Cache\CacheBackendInterface $cache
    *   Default cache bin.
    */
-  public function __construct(ConfigFactoryInterface $config_factory, EntityManagerInterface $entity_manager, CacheBackendInterface $cache) {
+  public function __construct(ConfigFactoryInterface $config_factory, EntityTypeManagerInterface $entity_manager, CacheBackendInterface $cache) {
     $this->configFactory = $config_factory;
     $this->termStorage = $entity_manager->getStorage('taxonomy_term');
     $this->cache = $cache;
@@ -163,7 +163,7 @@ class NodeOrderManager implements NodeOrderManagerInterface {
       }
       foreach ($tids as $index => $tid) {
         $term = $this->termStorage->load($tid);
-        $tree = $this->termStorage->loadTree($term->getVocabularyId(), $tid, $depth);
+        $tree = $this->termStorage->loadTree($term->bundle(), $tid, $depth);
         $descendant_tids[] = array_merge([$tid], array_map(function ($value) {
           return $value->id();
         }, $tree));
diff --git a/src/Tests/NodeorderCrudTest.php b/src/Tests/NodeorderCrudTest.php
index 0550d8e..0bf889b 100644
--- a/src/Tests/NodeorderCrudTest.php
+++ b/src/Tests/NodeorderCrudTest.php
@@ -3,7 +3,7 @@
 namespace Drupal\nodeorder\Tests;
 
 use Drupal\Core\Field\FieldStorageDefinitionInterface;
-use Drupal\taxonomy\Tests\TaxonomyTestBase;
+use \Drupal\Tests\taxonomy\Functional\TaxonomyTestBase;
 
 /**
  * Test CRUD operations that Nodeorder relies on.
@@ -310,12 +310,12 @@ class NodeorderCrudTest extends TaxonomyTestBase {
     }
 
     if (!empty($expected) || !empty($order)) {
-      debug($expected, 'Orderings that did not match.');
-      debug($order, 'Orderings found that were not expected.');
+      dump($expected, 'Orderings that did not match.');
+      dump($order, 'Orderings found that were not expected.');
       $this->fail('Order did not match.');
     }
     else {
-      $this->pass('Order of nodes matched.');
+      $this->assertTrue(TRUE, 'Order of nodes matched.');
     }
   }
 
