You are here

function acquia_contenthub_audit_publisher_finished in Acquia Content Hub 8

Prints results from the comparison of the tracking table with Content Hub.

Parameters

bool $success: TRUE if there were not PHP fatal errors, FALSE otherwise.

mixed $results: An array of results.

mixed $operations: The operations array.

2 string references to 'acquia_contenthub_audit_publisher_finished'
AcquiaContenthubCommands::contenthubAuditPublisher in src/Commands/AcquiaContenthubCommands.php
Checks published entities and republishes them to Content Hub.
drush_acquia_contenthub_audit_publisher in ./acquia_contenthub.drush.inc
Audits exported entities and republishes if inconsistencies are found.

File

./acquia_contenthub.module, line 426
Contains acquia_contenthub.module.

Code

function acquia_contenthub_audit_publisher_finished($success, $results, $operations) {

  // The 'success' parameter means no fatal PHP errors were detected. All
  // other error management should be handled using 'results'.
  if ($success) {
    Drush::output()
      ->writeln(dt('Total number of audited entities not found in Content Hub: @total', [
      '@total' => $results['not_published'],
    ]));
    Drush::output()
      ->writeln(dt('Total number of audited entities found outdated in Content Hub: @total', [
      '@total' => $results['outdated'],
    ]));
  }
  else {
    Drush::output()
      ->writeln(dt('Finished with a PHP fatal error.'));
  }
}