group-8.x-1.x-dev/modules/gnode/gnode.module

modules/gnode/gnode.module
<?php

/**
 * @file
 * Enables Group functionality for the Node module.
 */

use Drupal\Core\Entity\EntityInterface;
use Drupal\Core\Hook\Attribute\LegacyHook;
use Drupal\node\NodeTypeInterface;
use Drupal\gnode\Hook\EntityHooks;

/**
 * Implements hook_ENTITY_TYPE_insert().
 */
#[LegacyHook]
function gnode_node_type_insert(NodeTypeInterface $node_type) {
  \Drupal::service(EntityHooks::class)->nodeTypeInsert($node_type);
}

/**
 * Implements hook_entity_operation().
 */
#[LegacyHook]
function gnode_entity_operation(EntityInterface $entity) {
  return \Drupal::service(EntityHooks::class)->entityOperation($entity);
}

Главная | Обратная связь

drupal hosting | друпал хостинг | it patrol .inc