diff --git a/entity_copy_reference.module b/entity_copy_reference.module index 733bdec..d98001b 100644 --- a/entity_copy_reference.module +++ b/entity_copy_reference.module @@ -19,7 +19,7 @@ function entity_copy_reference_help($route_name, RouteMatchInterface $route_matc $output = ''; $output .= '

' . t('About') . '

'; $output .= '

' . t('Module for easy one click node copy/clone creation') . '

' . - '

' . t('The module allows for configuration as to what referenced entities should be copied + '

' . t('The module allows for configuration as to what referenced entities should be copied along with parent node (such as paragraphs or related content types') . '

'; return $output; @@ -65,6 +65,9 @@ function entity_copy_reference_menu_local_tasks_alter(&$data, $route_name, &$cac * Implements hook_entity_operation_alter(). */ function entity_copy_reference_entity_operation_alter(&$operations, $entity) { + if (!$entity instanceof \Drupal\node\Entity\Node) { + return; + } $entityCopyReference = new EntityCopyReference(); if ($entityCopyReference->isCopyEnabled($entity) && $entity->access('update')) {