Commit 2dd2ee38 authored by Charles Tanton's avatar Charles Tanton Committed by Bojan Živanović
Browse files

Issue #3028705 by foxtrotcharlie, joachim: allow entity types to specify their...

Issue #3028705 by foxtrotcharlie, joachim: allow entity types to specify their own bundle_plugin handler class
parent 753ed892
Loading
Loading
Loading
Loading
+2 −0
Changes for entity.module: 2 added lines, 0 removed lines.
Original line number Diff line number Diff line
@@ -53,10 +53,12 @@ function entity_get_bundle_plugin_entity_types() {
function entity_entity_type_build(array &$entity_types) {
  foreach ($entity_types as $entity_type) {
    if ($entity_type->get('bundle_plugin_type')) {
      if (!$entity_type->hasHandlerClass('bundle_plugin')) {
        $entity_type->setHandlerClass('bundle_plugin', BundlePluginHandler::class);
      }
    }
  }
}

/**
 * Implements hook_entity_bundle_info().