Drupal\Core\Entity\EntityDefinitionUpdateManager::updateEntityType(): Argument #1 ($entity_type) must be of type Drupal\Core\Entity\EntityTypeInterface, null given

Created on 27 April 2023, over 1 year ago

With Drupal 9.5.8 and php 8.0 when i make a updb i get this error:

crincon@resolstandard-web:/var/www/html$ vendor/bin/drush updb
-------------- ----------- --------------- ------------------------------------------------
Module Update ID Type Description
-------------- ----------- --------------- ------------------------------------------------
domain_alias 8001 hook_update_n 8001 - Updates domain_alias schema.
domain_alias 8002 hook_update_n 8002 - Adds domain_alias environment settings.
-------------- ----------- --------------- ------------------------------------------------

Do you wish to run the specified pending updates? (yes/no) [yes]:
>

> [notice] Update started: domain_alias_update_8001
> [error] Drupal\Core\Entity\EntityDefinitionUpdateManager::updateEntityType(): Argument #1 ($entity_type) must be of type Drupal\Core\Entity\EntityTypeInterface, null given, called in /var/www/html/web/modules/contrib/domain/domain_alias/domain_alias.install on line 26
> [error] Update failed: domain_alias_update_8001

The problem is that the method $manager->getEntityType('domain_alias') return a null, instead of a EntityTypeInterface.

I made a patch to check if this is not null, but i don't know if the problem is really in another place, and the main reason of the problem.

🐛 Bug report
Status

Active

Version

2.0

Component

Code

Created by

🇪🇸Spain Carlitus

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Production build 0.71.5 2024