Skip to content
Snippets Groups Projects
Unverified Commit 03456504 authored by Stefan Auditor's avatar Stefan Auditor Committed by Stefan Auditor
Browse files

Issue #3236771 by cecrs, sanduhrs: Entity Reference fields broken for PET...

Issue #3236771 by cecrs, sanduhrs: Entity Reference fields broken for PET Entities: Fix hook_update_n
parent 7a5f478e
Branches
Tags
No related merge requests found
......@@ -14,21 +14,10 @@ function pet_update_8401() {
\Drupal::database()->schema()->renameTable('pet', 'pets');
}
/**
* Update PET entity base_table annotation.
*/
function pet_update_8402() {
\Drupal::service('entity_field.manager')->clearCachedFieldDefinitions();
$key_value_store_definition = \Drupal::keyValue('entity.definitions.installed');
$storage_definitions = $key_value_store_definition->get('pet.entity_type');
$storage_definitions->set('base_table', 'pets');
$key_value_store_definition->set('pet.entity_type', $storage_definitions);
}
/**
* Update PET entity data_table annotation.
*/
function pet_update_8403() {
function pet_update_8402() {
\Drupal::service('entity_field.manager')->clearCachedFieldDefinitions();
$key_value_store_definition = \Drupal::keyValue('entity.definitions.installed');
$storage_definitions = $key_value_store_definition->get('pet.entity_type');
......@@ -39,7 +28,7 @@ function pet_update_8403() {
/**
* Add new machine_name base field.
*/
function pet_update_8404() {
function pet_update_8403() {
$field_storage_definition = BaseFieldDefinition::create('string')
->setLabel(t('Mail ID'))
->setDescription(t('The mail ID.'))
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment