Loading src/Commands/ContentSyncCommands.php +7 −2 Changes for src/Commands/ContentSyncCommands.php: 7 added lines, 2 removed lines. Original line number Diff line number Diff line Loading @@ -368,6 +368,10 @@ class ContentSyncCommands extends DrushCommands { $error = TRUE; $item = array_pop($context['sandbox']['queue']); list($entity_type_id, , $uuid) = explode('.', $item); if ($entity_type_id == 'user' && $uuid == $this->entityManager->getStorage('user')->load(1)->uuid()) { $message = $this->t('The super administrator user cannot be deleted.'); } else { $entity = $this->entityManager->loadEntityByUuid($entity_type_id, $uuid); if ($entity) { try { Loading @@ -390,6 +394,7 @@ class ContentSyncCommands extends DrushCommands { ]); } } } $context['results'][] = TRUE; $context['sandbox']['progress']++; $context['message'] = $message; Loading @@ -414,8 +419,8 @@ class ContentSyncCommands extends DrushCommands { if ($success) { if (!empty($results['errors'])) { foreach ($results['errors'] as $error) { \Drupal::getContainer()->get('content_sync.commands')->io()->writeln($error); \Drupal::logger('config_sync')->error($error); \Drupal::getContainer()->get('content_sync.commands')->io()->writeln($error->__toString()); \Drupal::logger('config_sync')->error($error->__toString()); } \Drupal::getContainer()->get('content_sync.commands')->io()->writeln(\Drupal::translation() ->translate('The content was imported with errors.')->__toString()); Loading Loading
src/Commands/ContentSyncCommands.php +7 −2 Changes for src/Commands/ContentSyncCommands.php: 7 added lines, 2 removed lines. Original line number Diff line number Diff line Loading @@ -368,6 +368,10 @@ class ContentSyncCommands extends DrushCommands { $error = TRUE; $item = array_pop($context['sandbox']['queue']); list($entity_type_id, , $uuid) = explode('.', $item); if ($entity_type_id == 'user' && $uuid == $this->entityManager->getStorage('user')->load(1)->uuid()) { $message = $this->t('The super administrator user cannot be deleted.'); } else { $entity = $this->entityManager->loadEntityByUuid($entity_type_id, $uuid); if ($entity) { try { Loading @@ -390,6 +394,7 @@ class ContentSyncCommands extends DrushCommands { ]); } } } $context['results'][] = TRUE; $context['sandbox']['progress']++; $context['message'] = $message; Loading @@ -414,8 +419,8 @@ class ContentSyncCommands extends DrushCommands { if ($success) { if (!empty($results['errors'])) { foreach ($results['errors'] as $error) { \Drupal::getContainer()->get('content_sync.commands')->io()->writeln($error); \Drupal::logger('config_sync')->error($error); \Drupal::getContainer()->get('content_sync.commands')->io()->writeln($error->__toString()); \Drupal::logger('config_sync')->error($error->__toString()); } \Drupal::getContainer()->get('content_sync.commands')->io()->writeln(\Drupal::translation() ->translate('The content was imported with errors.')->__toString()); Loading