Problem/Motivation

The latest hook update (shorthand_update_8002()) introduced by this commit creates new fields but it always fails with this error:

Drupal\Core\Entity\EntityStorageException with message 'Unsupported entity type '

Steps to reproduce

  • Install shorthand version 2.0
  • Update it to version 2.1
  • Run update.php (or drush updb)

Proposed resolution

Instead of using Drupal::entityDefinitionUpdateManager()->updateFieldableEntityType() to update the whole entity type, let's use Drupal::entityDefinitionUpdateManager()->installFieldStorageDefinition() to install each new field individually.

Remaining tasks

None

User interface changes

None

API changes

None

Data model changes

None

Issue fork shorthand-3203629

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

villette created an issue. See original summary.

villette’s picture

Here is a patch.

villette’s picture

Status: Active » Needs review
benhoad’s picture

Thanks immensely for picking this up - I'll roll out the fix today.

benhoad’s picture

Status: Needs review » Fixed

That should be merged in now.

Status: Fixed » Closed (fixed)

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