diff --git a/modules/ds_switch_view_mode/ds_switch_view_mode.module b/modules/ds_switch_view_mode/ds_switch_view_mode.module index 1c5d2eb..2974868 100644 --- a/modules/ds_switch_view_mode/ds_switch_view_mode.module +++ b/modules/ds_switch_view_mode/ds_switch_view_mode.module @@ -16,6 +16,10 @@ use Drupal\ds\Ds; * Implements hook_entity_base_field_info(). */ function ds_switch_view_mode_entity_base_field_info(EntityTypeInterface $entity_type) { + if ($entity_type->getBundleOf() != 'node') { + return; + } + // Add the switch field as a base field. $fields = array();