function domain_source_node_type_insert in Domain Access 8
Implements hook_ENTITY_TYPE_insert().
Creates our fields when new node types are created.
@TODO: Make this possible for all entity types.
File
- domain_source/
domain_source.module, line 81 - Domain-based path rewrites for content.
Code
function domain_source_node_type_insert(EntityInterface $entity) {
/** @var \Drupal\Core\Config\Entity\ConfigEntityInterface $entity */
if (!$entity
->isSyncing()) {
// Do not fire hook when config sync in progress.
domain_source_confirm_fields('node', $entity
->id());
}
}